Part Number Hot Search : 
B8279 242PC60G 72U20A 0LVEL LN9707 QL6500 CY7C4292 110TR
Product Description
Full Text Search
 

To Download PNX1502EG Datasheet File

  If you can't view the Datasheet, Please click here to try to view without PDF Reader .  
 
 


  Datasheet File OCR Text:
  pnx15xx series data book volume 1 of 1 connected media processor rev. 2 ?1 december 2004
philips semiconductors pnx15xx series volume 1 of 1 connected media processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -2 chapter 1: integrated circuit data 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-1 2. pin description . . . . . . . . . . . . . . . . . . . . . . . . . . 1-1 2.1 boundary scan notice . . . . . . . . . . . . . . . . . . . . . 1-1 2.2 i/o circuit summary . . . . . . . . . . . . . . . . . . . . . . . 1-1 2.3 signal pin list . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-3 2.3.1 power pin list . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-18 2.3.2 pin reference voltage . . . . . . . . . . . . . . . . . . . . 1-19 3. parametric characteristics . . . . . . . . . . . . . 1-19 3.1 absolute maximum ratings . . . . . . . . . . . . . . . 1-19 3.2 operating range and thermal characteristics .1- 20 4. power supplies sequence . . . . . . . . . . . . . . 1-20 5. power supply and operating speeds . . 1-21 6. power consumption . . . . . . . . . . . . . . . . . . . . 1-21 6.1 leakage current power consumption . . . . . . 1-21 6.2 standby power consumption . . . . . . . . . . . . . . 1-21 6.3 typical power consumption for typical applications 1-21 6.4 expected maximum currents . . . . . . . . . . . . . . 1-22 7. dc/ac i/o characteristics . . . . . . . . . . . . . . 1-22 7.1 input crystal specification . . . . . . . . . . . . . . . . 1-23 7.2 sstl_2 type i/o circuit . . . . . . . . . . . . . . . . . . . 1-23 7.3 bpx2t14mcp type i/o circuit . . . . . . . . . . . . 1-25 7.4 bpts1chp and bpts1cp type i/o circuit . 1-26 7.5 bpts3chp type i/o circuit . . . . . . . . . . . . . . . 1-27 7.6 ipchp and ipcp type i/o circuit . . . . . . . . . . 1-28 7.7 bpt3mchdt5v and bpt3mcht5v type i/o circuit 1-28 7.8 iic3m4sdat5v and iic3m4sclt5v type i/o circuit 1-29 7.9 pcit5v type i/o circuit . . . . . . . . . . . . . . . . . . . . 1-29 8. timing speci?ation . . . . . . . . . . . . . . . . . . . . 1-29 8.1 reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-30 8.2 ddr dram interface . . . . . . . . . . . . . . . . . . . . . 1-30 8.3 pci bus interface . . . . . . . . . . . . . . . . . . . . . . . . 1-31 8.4 qvcp, lcd and fgpo interfaces . . . . . . . . . . 1-33 8.5 vip and fgpi interfaces . . . . . . . . . . . . . . . . . . 1-34 8.6 10/100 lan in mii mode . . . . . . . . . . . . . . . . . . 1-34 8.7 10/100 lan in rmii mode . . . . . . . . . . . . . . . . . 1-35 8.8 audio input interface . . . . . . . . . . . . . . . . . . . . . 1-36 8.9 audio output interface . . . . . . . . . . . . . . . . . . . . 1-37 8.10 spdif i/o interface . . . . . . . . . . . . . . . . . . . . . . 1-38 8.11 i2c i/o interface . . . . . . . . . . . . . . . . . . . . . . . . . 1-39 8.12 gpio interface . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-40 8.13 jtag interface . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-41 9. package outline . . . . . . . . . . . . . . . . . . . . . . . . . 1-42 10. board design guidelines . . . . . . . . . . . . . . . 1-43 10.1 power supplies decoupling . . . . . . . . . . . . . . . 1-43 10.2 analog supplies . . . . . . . . . . . . . . . . . . . . . . . . . . 1-44 10.2.1 the 3.3 v analog supply . . . . . . . . . . . . . . . . . . 1-44 10.2.2 the 1.2-1.3-v analog supply . . . . . . . . . . . . . . 1-44 10.3 ddr sdram interface . . . . . . . . . . . . . . . . . . . . 1-45 10.3.1 do ddr devices require termination? . . . . . 1-46 10.3.2 what if i really want to use termination for the pnx1500? 1-46 10.4 package handling, soldering and thermal properties 1-46 11. miscellaneous . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-47 12. soft errors due to radiation . . . . . . . . . . . . 1-47 13. ordering information . . . . . . . . . . . . . . . . . . . . 1-47 chapter 2: overview 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1 1.1 pnx15xx series functional overview . . . . . . . 2-1 1.2 pnx15xx series features summary . . . . . . . . 2-3 2. pnx15xx series functional block diagram 2-5 3. system resources . . . . . . . . . . . . . . . . . . . . . . . 2-6 3.1 system reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-6 3.2 system booting . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-6 3.3 clock system . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-7 3.4 power management . . . . . . . . . . . . . . . . . . . . . . . 2-7 3.5 semaphores . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-8 3.6 i2c interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-8 4. system memory . . . . . . . . . . . . . . . . . . . . . . . . . 2-9 4.1 mmi - main memory interface . . . . . . . . . . . . . . 2-9 4.2 flash . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-9 5. tm3260 vliw media processor core . . . 2-10 6. mpeg decoding . . . . . . . . . . . . . . . . . . . . . . . . 2-12 6.1 vld . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-12 6.2 dvd de-scrambler . . . . . . . . . . . . . . . . . . . . . . . 2-12 7. image processing . . . . . . . . . . . . . . . . . . . . . . . 2-12 7.1 pixel format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-12 7.2 video input processor . . . . . . . . . . . . . . . . . . . . 2-14 7.3 memory based scaler . . . . . . . . . . . . . . . . . . . . 2-14 7.4 2d drawing and dma engine . . . . . . . . . . . . . . 2-15 7.5 quality video composition processor . . . . . . . 2-15 7.5.1 external video improvement post processing .2- 17 8. audio processing and input/output . . . . 2-17 8.1 audio processing . . . . . . . . . . . . . . . . . . . . . . . . 2-17 8.2 audio inputs and outputs . . . . . . . . . . . . . . . . . 2-17 9. general purpose interfaces . . . . . . . . . . . . . 2-18 9.1 video/data input router . . . . . . . . . . . . . . . . . . 2-18 9.2 video/data output router . . . . . . . . . . . . . . . . . 2-19 9.3 fast general purpose input . . . . . . . . . . . . . . . 2-20 9.4 fast general purpose output . . . . . . . . . . . . . . 2-21 10. peripheral interface . . . . . . . . . . . . . . . . . . . . . 2-21 10.1 gpio - general purpose software i/o and flexible serial interface 2-21 10.1.1 software i/o . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-22 table of contents
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -3 10.1.2 timestamping . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-22 10.1.3 event sequence monitoring and signal generation 2-22 10.1.4 gpio pin reset value . . . . . . . . . . . . . . . . . . . . . 2-23 10.2 ir remote control receiver and blaster . . . . 2-23 10.3 pci-2.2 & xio-16 bus interface unit . . . . . . . 2-23 10.3.1 pci capabilities . . . . . . . . . . . . . . . . . . . . . . . . . 2-24 10.3.2 simple peripheral capabilities (?io-8/16? . . 2-24 10.3.3 ide drive interface . . . . . . . . . . . . . . . . . . . . . . . 2-26 10.4 10/100 ethernet mac . . . . . . . . . . . . . . . . . . . . . 2-26 11. endian modes . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-26 12. system debug . . . . . . . . . . . . . . . . . . . . . . . . . . 2-27 chapter 3: system on chip resources 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-1 2. system memory map . . . . . . . . . . . . . . . . . . . . 3-1 2.1 the pci view . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-2 2.2 the cpu view . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-3 2.3 the dcs view or the system view . . . . . . . . 3-4 2.4 the programmable dcs apertures . . . . . . . . . 3-5 2.4.1 dcs dram aperture control mmio registers 3-6 2.5 aperture boundaries . . . . . . . . . . . . . . . . . . . . . . 3-6 3. system principles . . . . . . . . . . . . . . . . . . . . . . . 3-7 3.1 module id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-7 3.2 powerdown bit . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-7 3.3 system module mmio registers . . . . . . . . . . . . 3-8 4. system endian mode . . . . . . . . . . . . . . . . . . . . 3-8 4.1 system endian mode mmio registers . . . . . . . 3-9 5. system semaphores . . . . . . . . . . . . . . . . . . . . 3-9 5.1 semaphore specification . . . . . . . . . . . . . . . . . . 3-9 5.2 construction of a 12-bit id . . . . . . . . . . . . . . . . . 3-9 5.3 the master semaphore . . . . . . . . . . . . . . . . . . . 3-10 5.4 usage notes . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-10 5.5 semaphore mmio registers . . . . . . . . . . . . . . . 3-11 6. system related information for tm3260 3-12 6.1 interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-12 6.2 timers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-14 6.3 system parameters for tm3260 . . . . . . . . . . . 3-15 6.3.1 tm3260 system parameters mmio registers .3- 16 7. video input and output routers . . . . . . . . 3-16 7.1 mmio registers for the input/output video/data router 3-17 8. miscellaneous . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-26 8.1 miscellaneous system mmio registers . . . . . . 3-27 9. system registers map summary . . . . . . . 3-29 10. simpli?d internal bus infrastructure . . 3-30 11. mmio memory map . . . . . . . . . . . . . . . . . . . . . 3-31 12. references . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-32 chapter 4: reset 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-1 2. functional description . . . . . . . . . . . . . . . . . . 4-1 2.1 reset_in_n or por_in_n? . . . . . . . . . . . . . . 4-3 2.2 the watchdog timer . . . . . . . . . . . . . . . . . . . . . . 4-4 2.2.1 the non interrupt mode . . . . . . . . . . . . . . . . . . . 4-4 2.2.2 the interrupt mode . . . . . . . . . . . . . . . . . . . . . . . . 4-5 2.3 the software reset . . . . . . . . . . . . . . . . . . . . . . . 4-6 2.4 the external software reset . . . . . . . . . . . . . . . 4-6 3. timing description . . . . . . . . . . . . . . . . . . . . . . . 4-7 3.1 the hardware timing . . . . . . . . . . . . . . . . . . . . . . 4-7 3.2 the software timing . . . . . . . . . . . . . . . . . . . . . . 4-8 4. register de?itions . . . . . . . . . . . . . . . . . . . . . . 4-9 5. references . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-10 chapter 5: the clock module 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-1 2. functional description . . . . . . . . . . . . . . . . . . 5-1 2.1 the modules and their clocks . . . . . . . . . . . . . . 5-4 2.2 clock sources for pnx15xx series . . . . . . . . . . 5-7 2.2.1 pll specification . . . . . . . . . . . . . . . . . . . . . . . . . 5-8 2.2.2 the clock dividers . . . . . . . . . . . . . . . . . . . . . . . 5-10 2.2.3 the dds clocks . . . . . . . . . . . . . . . . . . . . . . . . . 5-11 2.2.4 dds and pll assignment summary . . . . . . . 5-11 2.2.5 external clocks . . . . . . . . . . . . . . . . . . . . . . . . . . 5-11 2.3 clock control logic . . . . . . . . . . . . . . . . . . . . . . 5-13 2.4 bypass clock sources . . . . . . . . . . . . . . . . . . . . 5-14 2.5 power-up and reset sequence . . . . . . . . . . . . 5-15 2.6 clock stretching . . . . . . . . . . . . . . . . . . . . . . . . . 5-15 2.7 clock frequency determination . . . . . . . . . . . 5-16 2.8 power down . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-17 2.8.1 wake-up from power down . . . . . . . . . . . . . . . 5-17 2.9 clock detection . . . . . . . . . . . . . . . . . . . . . . . . . . 5-18 2.10 vdo clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-19 2.11 gpio clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-20 2.11.1 setting gpio[14:12]/gclock[2:0] as clock outputs 5-20 2.11.2 gpio[6:4]/clock[6:4] as clock outputs . . . . 5-20 2.12 clock block diagrams . . . . . . . . . . . . . . . . . . . . 5-20 2.12.1 tm3260, ddr and qvcp clocks . . . . . . . . . . . 5-21 2.12.2 clock dividers . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-23 2.12.3 internal pnx15xx series clock from dividers 5-24 2.12.4 gpio clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-26 2.12.5 external clocks . . . . . . . . . . . . . . . . . . . . . . . . . . 5-27 2.12.6 spdo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-31 3. registers de?ition . . . . . . . . . . . . . . . . . . . . . 5-31 3.1 registers summary . . . . . . . . . . . . . . . . . . . . . . 5-31 3.2 registers description . . . . . . . . . . . . . . . . . . . . . 5-34
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -4 chapter 6: boot module 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-1 2. functional description . . . . . . . . . . . . . . . . . . 6-1 2.1 the boot modes . . . . . . . . . . . . . . . . . . . . . . . . . . 6-2 2.2 boot module operation . . . . . . . . . . . . . . . . . . . . 6-4 2.2.1 mmio bus interface . . . . . . . . . . . . . . . . . . . . . . . 6-4 2.2.2 i2c master . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-4 2.2.3 boot control/state machine . . . . . . . . . . . . . . . . 6-5 2.3 the boot command language . . . . . . . . . . . . . 6-5 3. pnx15xx series boot scripts content . . . 6-6 3.1 the common behavior . . . . . . . . . . . . . . . . . . . . 6-6 3.1.1 binary sequence for the common boot script 6-9 3.2 the specifics of the boot from flash memory devices 6-10 3.2.1 binary sequence for the section of the flash boot 6-12 3.3 the specifics of the host-assisted mode . . . . 6-12 4. the boot from an i2c eeprom . . . . . . . . 6-14 4.1 external i2c boot eeprom types . . . . . . . . . 6-14 4.2 the boot commands and the endian mode . 6-15 4.3 details on i2c operation . . . . . . . . . . . . . . . . . . 6-15 5. references . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-16 chapter 7: pci-xio module 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-1 2. functional description . . . . . . . . . . . . . . . . . . 7-2 2.1 document title variable block level diagram . 7-3 2.2 architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4 3.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4 3.1.1 nand-flash interface operation . . . . . . . . . . . . 7-5 3.1.2 motorola style interface . . . . . . . . . . . . . . . . . . 7-10 3.1.3 nor flash interface . . . . . . . . . . . . . . . . . . . . . 7-11 3.1.4 ide description . . . . . . . . . . . . . . . . . . . . . . . . . . 7-13 3.2 pci interrupt enable register . . . . . . . . . . . . . 7-17 4. application notes . . . . . . . . . . . . . . . . . . . . . . . 7-18 4.1 dtl interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-18 4.2 system memory bus interface, the mtl bus 7-18 4.3 xio interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-19 4.3.1 motorola interface . . . . . . . . . . . . . . . . . . . . . . . . 7-19 4.3.2 nand-flash interface . . . . . . . . . . . . . . . . . . . . 7-19 4.3.3 nor flash interface . . . . . . . . . . . . . . . . . . . . . . 7-19 4.3.4 ide interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-20 4.4 pci endian support . . . . . . . . . . . . . . . . . . . . . . 7-20 4.5 general notes . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-20 5. register descriptions . . . . . . . . . . . . . . . . . . . 7-20 5.1 register summary . . . . . . . . . . . . . . . . . . . . . . . 7-21 chapter 8: general purpose input output pins 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-1 2. functional description . . . . . . . . . . . . . . . . . . 8-2 2.1 gpio: the basic pin behavior . . . . . . . . . . . . . . 8-2 2.1.1 gpio mode settings . . . . . . . . . . . . . . . . . . . . . . . 8-4 2.1.2 gpio data settings mmio registers . . . . . . . . 8-4 2.1.3 gpio pin status reading . . . . . . . . . . . . . . . . . . 8-6 2.2 gpio: the event monitoring mode . . . . . . . . . . 8-6 2.2.1 timestamp reference clock . . . . . . . . . . . . . . . . 8-7 2.2.2 timestamp format . . . . . . . . . . . . . . . . . . . . . . . . . 8-7 2.3 gpio: the signal monitoring & pattern generation modes 8-7 2.3.1 the signal monitoring mode . . . . . . . . . . . . . . . . 8-8 2.3.2 the signal pattern generation mode . . . . . . . 8-11 2.4 gpio error behaviour . . . . . . . . . . . . . . . . . . . . 8-14 2.4.1 gpio frequency restrictions . . . . . . . . . . . . . . 8-15 2.5 the gpio clock pins . . . . . . . . . . . . . . . . . . . . . 8-17 2.6 gpio interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . 8-17 2.7 timer sources . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-18 2.8 wake-up interrupt . . . . . . . . . . . . . . . . . . . . . . . . 8-18 2.9 external watchdog . . . . . . . . . . . . . . . . . . . . . . . 8-18 3. ir applications . . . . . . . . . . . . . . . . . . . . . . . . . 8-18 3.1 duty-cycle programming . . . . . . . . . . . . . . . . . . 8-19 3.2 spike filtering . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-20 4. mmio registers . . . . . . . . . . . . . . . . . . . . . . . . . 8-21 4.1 gpio mode control registers . . . . . . . . . . . . . 8-24 4.2 gpio data control . . . . . . . . . . . . . . . . . . . . . . . 8-26 4.3 readable internal pnx15xx series signals . . 8-26 4.4 sampling and pattern generation control registers for the fifo queues 8-27 4.5 signal and event monitoring control registers for the timestamp units 8-34 4.6 timestamp unit registers . . . . . . . . . . . . . . . . . 8-34 4.7 gpio time counter . . . . . . . . . . . . . . . . . . . . . . 8-34 4.8 gpio tm3260 timer input select . . . . . . . . . . 8-35 4.9 gpio interrupt status . . . . . . . . . . . . . . . . . . . . . 8-35 4.10 clock out select . . . . . . . . . . . . . . . . . . . . . . . . . 8-36 4.11 gpio interrupt registers for the fifo queues (one for each fifo queue) 8-37 4.12 gpio module status register for all 12 timestamp units 8-38 4.13 gpio powerdown . . . . . . . . . . . . . . . . . . . . 8-43 4.14 gpio module id . . . . . . . . . . . . . . . . . . . . . . . . . 8-43 4.15 gpio io_sel selection values . . . . . . . . . . . . 8-43 chapter 9: ddr controller 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-1 2. functional description . . . . . . . . . . . . . . . . . . . 9-1
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -5 2.1 start and warm start . . . . . . . . . . . . . . . . . . . . . . 9-2 2.1.1 the start mode . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-2 2.1.2 warm start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-2 2.1.3 observing start state . . . . . . . . . . . . . . . . . . . . . 9-3 2.2 arbitration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-3 2.2.1 the first level of arbitration: between the dma and the cpu 9-3 2.2.2 second level of arbitration . . . . . . . . . . . . . . . . . 9-6 2.2.3 dynamic ratios . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-6 2.2.4 pre-emption . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-8 2.2.5 back log buffer (blb) . . . . . . . . . . . . . . . . . . . . . 9-9 2.2.6 pman (hub) versus ddr controller interaction 9- 9 2.3 addressing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-10 2.3.1 memory region mapping scheme . . . . . . . . . 9-10 2.3.2 ddr memory rank locations . . . . . . . . . . . . . 9-12 2.4 clock programming . . . . . . . . . . . . . . . . . . . . . . 9-13 2.5 power management . . . . . . . . . . . . . . . . . . . . . . 9-13 2.5.1 halting and unhalting . . . . . . . . . . . . . . . . . . . . 9-14 2.5.2 mmio directed halt . . . . . . . . . . . . . . . . . . . . . . 9-14 2.5.3 auto halt . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-14 2.5.4 observing halt mode . . . . . . . . . . . . . . . . . . . . . 9-15 2.5.5 sequence of actions . . . . . . . . . . . . . . . . . . . . . 9-16 3. application notes . . . . . . . . . . . . . . . . . . . . . . . 9-16 3.1 memory configurations . . . . . . . . . . . . . . . . . . . 9-16 3.2 error signaling . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-17 3.3 latency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-17 3.4 data coherency . . . . . . . . . . . . . . . . . . . . . . . . . . 9-18 3.5 programming the internal arbiter . . . . . . . . . . . 9-18 3.6 the ddr controller and the ddr memory devices 9-20 4. timing diagrams and tables . . . . . . . . . . . . 9-20 4.0.1 tcas timing parameter . . . . . . . . . . . . . . . . . . . 9-21 4.1 trrd and trc timing parameters . . . . . . . . . . . 9-21 4.2 trfc timing parameter . . . . . . . . . . . . . . . . . . . . 9-21 4.3 twr timing parameter . . . . . . . . . . . . . . . . . . . . 9-22 4.4 tras timing parameter . . . . . . . . . . . . . . . . . . . 9-22 4.5 trp timing parameter . . . . . . . . . . . . . . . . . . . . 9-22 4.6 trcd_rd timing parameter . . . . . . . . . . . . . . . . . 9-23 4.7 trcd_wr timing parameter . . . . . . . . . . . . . . . . 9-23 5. register descriptions . . . . . . . . . . . . . . . . . . . 9-23 5.1 register summary . . . . . . . . . . . . . . . . . . . . . . . 9-24 5.2 register table . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-25 6. references . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-32 chapter 10: lcd controller 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-1 1.1 lcd controller features . . . . . . . . . . . . . . . . . . 10-1 2. functional description . . . . . . . . . . . . . . . . . 10-1 2.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-1 2.2 power sequencing . . . . . . . . . . . . . . . . . . . . . . . 10-2 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-3 3.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-3 3.2 power sequencing state machine . . . . . . . . . 10-3 3.2.1 idle state . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-4 3.2.2 dcen state . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-4 3.2.3 blen state . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-5 3.2.4 peped state . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-5 3.3 counter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-5 3.4 gating logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-5 4. register descriptions . . . . . . . . . . . . . . . . . . . 10-6 4.1 lcd mmio registers . . . . . . . . . . . . . . . . . . . . . 10-7 chapter 11: qvcp 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-2 2. functional description . . . . . . . . . . . . . . . . . 11-4 2.1 qvcp block diagram . . . . . . . . . . . . . . . . . . . . 11-4 2.2 architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-5 2.3 layer resources and functions . . . . . . . . . . . 11-6 2.3.1 memory access control (dma ctrl) . . . . . . 11-6 2.3.2 pixel formatter unit (pfu) . . . . . . . . . . . . . . . . 11-7 2.3.3 chroma key and undither (ckey/udth) unit 11- 7 2.3.4 chroma upsample filter (cups) . . . . . . . . . 11-11 2.3.5 linear interpolator (lint) . . . . . . . . . . . . . . . . 11-11 2.3.6 video/graphics contrast brightness matrix (vcbm) 11-11 2.3.7 layer and fetch control . . . . . . . . . . . . . . . . . 11-12 2.4 pool resources and functions . . . . . . . . . . . 11-13 2.4.1 clut (color look up table) . . . . . . . . . . . . . 11-13 2.4.2 dcti (digital chroma/color transient improvement) 11-13 2.4.3 hsru (horizontal sample rate upconverter) . 11- 13 2.4.4 hist (histogram modification) unit . . . . . . . . 11-14 2.4.5 lshr (luminance/luma sharpening) unit . 11-14 2.4.6 color features (cftr) unit . . . . . . . . . . . . . . 11-14 2.4.7 plan (semi planar dma) unit . . . . . . . . . . . . 11-15 2.5 screen timing generator . . . . . . . . . . . . . . . . 11-15 2.6 mixer structure . . . . . . . . . . . . . . . . . . . . . . . . . 11-16 2.6.1 key generation . . . . . . . . . . . . . . . . . . . . . . . . . 11-18 2.6.2 alpha blending . . . . . . . . . . . . . . . . . . . . . . . . . . 11-19 2.7 output pipeline structure . . . . . . . . . . . . . . . . . 11-19 2.7.1 supported output formats . . . . . . . . . . . . . . . 11-20 2.7.2 layer selection . . . . . . . . . . . . . . . . . . . . . . . . . 11-20 2.7.3 chrominance downsampling (cdns) . . . . . . 11-20 2.7.4 gamma correction and noise shaping (gnsh& onsh) 11-20 2.7.5 output interface modes . . . . . . . . . . . . . . . . . . 11-21 2.7.6 auxiliary pins . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-22 3. programming and resource assignment . 11-23
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -6 3.1 mmio and task based programming . . . . . 11-23 3.2 setup order for the qvcp . . . . . . . . . . . . . . . 11-24 3.2.1 shadow registers . . . . . . . . . . . . . . . . . . . . . . 11-25 3.2.2 fast access registers . . . . . . . . . . . . . . . . . . . 11-29 3.3 programming of layer and pool resources 11-30 3.3.1 resource assignment and selection . . . . . . 11-30 3.3.2 aperture assignment . . . . . . . . . . . . . . . . . . . . 11-30 3.3.3 data flow selection . . . . . . . . . . . . . . . . . . . . . 11-32 3.3.4 pool resource assignment example . . . . . . 11-34 3.4 programming the stg . . . . . . . . . . . . . . . . . . . 11-35 3.4.1 changing timing . . . . . . . . . . . . . . . . . . . . . . . . 11-36 3.5 programming qvcp for different output formats 11-36 4. application notes . . . . . . . . . . . . . . . . . . . . . . 11-37 4.1 special features . . . . . . . . . . . . . . . . . . . . . . . . 11-37 4.1.1 signature analysis . . . . . . . . . . . . . . . . . . . . . . 11-37 4.2 programming help . . . . . . . . . . . . . . . . . . . . . . 11-37 4.3 lint parameters . . . . . . . . . . . . . . . . . . . . . . . . 11-38 4.4 hsru parameters . . . . . . . . . . . . . . . . . . . . . . 11-38 4.5 lshr parameters . . . . . . . . . . . . . . . . . . . . . . . 11-39 4.6 dcti parameters . . . . . . . . . . . . . . . . . . . . . . . 11-40 4.7 cftr parameters . . . . . . . . . . . . . . . . . . . . . . . 11-40 4.8 underflow behavior . . . . . . . . . . . . . . . . . . . . . 11-40 4.8.1 layer underflow . . . . . . . . . . . . . . . . . . . . . . . . 11-41 4.8.2 underflow symptom . . . . . . . . . . . . . . . . . . . . . 11-41 4.8.3 underflow recovery . . . . . . . . . . . . . . . . . . . . . 11-41 4.8.4 underflow trouble-shooting . . . . . . . . . . . . . . 11-41 4.8.5 underflow handling . . . . . . . . . . . . . . . . . . . . . 11-41 4.9 clock calculations . . . . . . . . . . . . . . . . . . . . . . . 11-42 5. register descriptions . . . . . . . . . . . . . . . . . . 11-43 5.1 register summary . . . . . . . . . . . . . . . . . . . . . . 11-43 5.2 register tables . . . . . . . . . . . . . . . . . . . . . . . . . 11-46 chapter 12: video input processor 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-1 2. functional description . . . . . . . . . . . . . . . . . 12-2 2.1 vip block level diagram . . . . . . . . . . . . . . . . . 12-2 2.2 chip i/o and connections . . . . . . . . . . . . . . . . . 12-3 2.2.1 data routing and video modes . . . . . . . . . . . . 12-3 2.2.2 input timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-4 2.3 test pattern generator . . . . . . . . . . . . . . . . . . . 12-4 2.4 input formats . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-5 2.5 video data path . . . . . . . . . . . . . . . . . . . . . . . . . 12-8 2.5.1 video data flow . . . . . . . . . . . . . . . . . . . . . . . . . 12-8 2.5.2 video data acquisition . . . . . . . . . . . . . . . . . . . . 12-8 2.5.3 internal timing . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-9 2.5.4 field identifier generation . . . . . . . . . . . . . . . . . 12-9 2.5.5 horizontal video filters (sampling, scaling, color space conversion) 12-12 2.5.6 video data write to memory . . . . . . . . . . . . . . 12-13 2.5.7 auxiliary data path . . . . . . . . . . . . . . . . . . . . . . 12-15 2.5.8 interrupt generation . . . . . . . . . . . . . . . . . . . . . 12-19 3. register descriptions . . . . . . . . . . . . . . . . . . 12-19 3.1 register summary . . . . . . . . . . . . . . . . . . . . . . 12-19 3.2 register table . . . . . . . . . . . . . . . . . . . . . . . . . . 12-21 chapter 13: fgpo: fast general purpose output 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-1 1.1 fgpo overview . . . . . . . . . . . . . . . . . . . . . . . . . 13-2 1.2 fgpo to vdo pin mapping . . . . . . . . . . . . . . . 13-3 1.3 dtl mmio interface . . . . . . . . . . . . . . . . . . . . . 13-3 1.4 header initiator . . . . . . . . . . . . . . . . . . . . . . . . . . 13-3 1.5 data initiator . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-3 1.6 record output mode . . . . . . . . . . . . . . . . . . . . . 13-3 1.7 message passing mode . . . . . . . . . . . . . . . . . . 13-4 2. functional description . . . . . . . . . . . . . . . . . 13-5 2.1 stopping clk_fgpo for output flow control . . . . 13-6 2.2 reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-6 2.3 base addresses . . . . . . . . . . . . . . . . . . . . . . . . . 13-6 2.4 sample (data) size . . . . . . . . . . . . . . . . . . . . . . . 13-7 2.5 record or message size . . . . . . . . . . . . . . . . . . 13-7 2.6 records or messages per buffer . . . . . . . . . . 13-7 2.7 stride . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-7 2.8 interrupt events . . . . . . . . . . . . . . . . . . . . . . . . . . 13-7 2.8.1 buf1done and buf2done interrupts . . . . 13-8 2.8.2 thresh1_reached and thresh2_reached interrupts 13-8 2.8.3 underrun interrupt . . . . . . . . . . . . . . . . . . . . 13-8 2.8.4 mbe interrupt . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-8 2.9 record or message counters . . . . . . . . . . . . . . 13-9 2.10 timestamp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-10 2.11 variable length . . . . . . . . . . . . . . . . . . . . . . . . . 13-10 2.12 output time registers . . . . . . . . . . . . . . . . . . . 13-10 2.13 double buffer operation . . . . . . . . . . . . . . . . . 13-10 2.14 single buffer operation . . . . . . . . . . . . . . . . . . 13-11 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-11 3.1 both operating modes . . . . . . . . . . . . . . . . . . . 13-11 3.1.1 setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-11 3.1.2 interrupt service routines . . . . . . . . . . . . . . . . 13-12 3.1.3 optimized dma transfers . . . . . . . . . . . . . . . . 13-12 3.1.4 terminating dma transfers . . . . . . . . . . . . . . 13-12 3.1.5 signal edge definitions . . . . . . . . . . . . . . . . . . 13-12 3.2 message passing mode . . . . . . . . . . . . . . . . . . 13-13 3.3 pnx1300 series message passing mode . . 13-13 3.4 record output mode . . . . . . . . . . . . . . . . . . . . 13-13 3.4.1 record synchronization events . . . . . . . . . . . 13-14 3.4.2 buffer synchronization events . . . . . . . . . . . . 13-14 4. register descriptions . . . . . . . . . . . . . . . . . . 13-15 4.1 mode register setup . . . . . . . . . . . . . . . . . . . . 13-15 4.2 status registers . . . . . . . . . . . . . . . . . . . . . . . . 13-20
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -7 chapter 14: fgpi: fast general purpose interface 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-1 1.1 fgpi overview . . . . . . . . . . . . . . . . . . . . . . . . . . 14-2 1.2 vdi to fgpi pin mapping . . . . . . . . . . . . . . . . . 14-3 1.3 dtl mmio interface . . . . . . . . . . . . . . . . . . . . . 14-3 1.4 data packer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-3 1.4.1 8-bit sample packing mode . . . . . . . . . . . . . . . 14-4 1.4.2 16-bit sample packing mode . . . . . . . . . . . . . . 14-4 1.4.3 32-bit sample mode . . . . . . . . . . . . . . . . . . . . . . 14-4 1.5 record capture mode . . . . . . . . . . . . . . . . . . . . 14-4 1.6 message passing mode . . . . . . . . . . . . . . . . . . 14-4 2. functional description . . . . . . . . . . . . . . . . . 14-6 2.1 reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-6 2.2 base addresses . . . . . . . . . . . . . . . . . . . . . . . . . 14-7 2.3 sample (data) size . . . . . . . . . . . . . . . . . . . . . . . 14-7 2.4 record or message size . . . . . . . . . . . . . . . . . . 14-7 2.5 records or messages per buffer . . . . . . . . . . 14-8 2.6 stride . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-8 2.7 interrupt events . . . . . . . . . . . . . . . . . . . . . . . . . . 14-8 2.7.1 buf1full and buf2full interrupts . . . . . . 14-8 2.7.2 thresh1_reached and thresh2_reached interrupts 14-8 2.7.3 overrun interrupt . . . . . . . . . . . . . . . . . . . . . . 14-8 2.7.4 mbe interrupt . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-9 2.7.5 overflow interrupt (message passing mode only) 14-9 2.8 record or message counters . . . . . . . . . . . . . . 14-9 2.9 timestamp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-9 2.10 variable length . . . . . . . . . . . . . . . . . . . . . . . . . 14-10 2.11 double buffer operation . . . . . . . . . . . . . . . . . 14-10 2.12 single buffer operation . . . . . . . . . . . . . . . . . . 14-11 2.13 buffer synchronization . . . . . . . . . . . . . . . . . . . 14-12 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-12 3.1 both operating modes . . . . . . . . . . . . . . . . . . . 14-12 3.1.1 setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-12 3.1.2 interrupt service routines . . . . . . . . . . . . . . . . 14-13 3.1.3 optimized dma transfers . . . . . . . . . . . . . . . . 14-13 3.1.4 terminating dma transfers . . . . . . . . . . . . . . 14-13 3.1.5 signal edge definitions . . . . . . . . . . . . . . . . . . 14-13 3.2 message passing mode . . . . . . . . . . . . . . . . . . 14-14 3.2.1 minimum message/record size . . . . . . . . . . . 14-14 3.3 pnx1300 series message passing mode . . 14-15 3.4 record capture mode . . . . . . . . . . . . . . . . . . . 14-15 3.4.1 record synchronization . . . . . . . . . . . . . . . . . . 14-15 3.4.2 buffer synchronization . . . . . . . . . . . . . . . . . . . 14-15 3.4.3 setup and operation with input router vdi_mode[7] = 1 14-16 4. register descriptions . . . . . . . . . . . . . . . . . . 14-18 4.1 mode registers . . . . . . . . . . . . . . . . . . . . . . . . . 14-18 4.2 status registers . . . . . . . . . . . . . . . . . . . . . . . . 14-21 chapter 15: audio output 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-1 2. functional description . . . . . . . . . . . . . . . . . 15-1 2.1 external interface . . . . . . . . . . . . . . . . . . . . . . . . 15-2 2.2 memory data formats . . . . . . . . . . . . . . . . . . . . 15-4 2.2.1 endian control . . . . . . . . . . . . . . . . . . . . . . . . . . 15-4 2.3 audio out data dma operation . . . . . . . . . . . 15-5 2.3.1 trans_enable . . . . . . . . . . . . . . . . . . . . . . . . 15-5 2.4 interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-6 2.4.1 interrupt latency . . . . . . . . . . . . . . . . . . . . . . . . . 15-6 2.5 timestamp events . . . . . . . . . . . . . . . . . . . . . . . 15-6 2.6 serial data framing . . . . . . . . . . . . . . . . . . . . . . 15-6 2.6.1 serial frame limitations . . . . . . . . . . . . . . . . . . 15-8 2.6.2 ws characteristics . . . . . . . . . . . . . . . . . . . . . . . 15-8 2.6.3 i 2 s serial framing example . . . . . . . . . . . . . . . 15-8 2.7 codec control . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-9 2.8 data bus latency and hbe . . . . . . . . . . . . . . . 15-10 2.9 error behavior . . . . . . . . . . . . . . . . . . . . . . . . . . 15-11 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-12 3.1 clock programming . . . . . . . . . . . . . . . . . . . . . 15-12 3.1.1 sample clock generator . . . . . . . . . . . . . . . . . 15-12 3.1.2 clock system operation . . . . . . . . . . . . . . . . . 15-13 3.2 reset-related issues . . . . . . . . . . . . . . . . . . . . 15-14 3.3 register programming guidelines . . . . . . . . . 15-14 3.4 power management . . . . . . . . . . . . . . . . . . . . . 15-14 4. register descriptions . . . . . . . . . . . . . . . . . . 15-15 4.1 register summary . . . . . . . . . . . . . . . . . . . . . . 15-15 4.2 register table . . . . . . . . . . . . . . . . . . . . . . . . . . 15-15 chapter 16: audio input 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-1 2. functional description . . . . . . . . . . . . . . . . . 16-2 2.1 chip level external interface . . . . . . . . . . . . . . 16-3 2.2 general operations . . . . . . . . . . . . . . . . . . . . . . 16-4 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-5 3.1 clock programming . . . . . . . . . . . . . . . . . . . . . . 16-5 3.1.1 clock system operation . . . . . . . . . . . . . . . . . . 16-5 3.2 reset-related issues . . . . . . . . . . . . . . . . . . . . 16-6 3.3 register programming guidelines . . . . . . . . . 16-7 3.4 serial data framing . . . . . . . . . . . . . . . . . . . . . . 16-7 3.5 memory data formats . . . . . . . . . . . . . . . . . . . 16-10 3.5.1 endian control . . . . . . . . . . . . . . . . . . . . . . . . . . 16-10 3.6 memory buffers and capture . . . . . . . . . . . . . 16-11 3.7 data bus latency and hbe . . . . . . . . . . . . . . . 16-11 3.8 error behavior . . . . . . . . . . . . . . . . . . . . . . . . . . 16-12 3.9 interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-12 3.10 timestamp events . . . . . . . . . . . . . . . . . . . . . . 16-13 3.11 diagnostic mode . . . . . . . . . . . . . . . . . . . . . . . . 16-13 3.12 software reset . . . . . . . . . . . . . . . . . . . . . . . . . 16-14 3.13 raw mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-15
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -8 4. register descriptions . . . . . . . . . . . . . . . . . 16-15 4.1 register table . . . . . . . . . . . . . . . . . . . . . . . . . . 16-15 chapter 17: spdif output 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-1 2. functional description . . . . . . . . . . . . . . . . . 17-2 2.1 architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-2 2.2 general operations . . . . . . . . . . . . . . . . . . . . . . 17-2 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-2 3.1 clock programming . . . . . . . . . . . . . . . . . . . . . . 17-2 3.1.1 sample rate programming . . . . . . . . . . . . . . . 17-2 3.2 register programming guidelines . . . . . . . . . 17-3 3.3 data formatting . . . . . . . . . . . . . . . . . . . . . . . . . 17-4 3.3.1 iec-60958 serial format . . . . . . . . . . . . . . . . . 17-4 3.3.2 transparent mode . . . . . . . . . . . . . . . . . . . . . . . 17-6 3.4 errors and interrupts . . . . . . . . . . . . . . . . . . . . . . 17-6 3.4.1 dma error conditions . . . . . . . . . . . . . . . . . . . . 17-6 3.4.2 hbe and latency . . . . . . . . . . . . . . . . . . . . . . . . 17-7 3.4.3 interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-7 3.4.4 timestamp events . . . . . . . . . . . . . . . . . . . . . . . 17-7 3.5 endian mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-8 4. signal description . . . . . . . . . . . . . . . . . . . . . . 17-8 4.1 external interface . . . . . . . . . . . . . . . . . . . . . . . . 17-8 5. register descriptions . . . . . . . . . . . . . . . . . . . 17-8 5.1 register summary . . . . . . . . . . . . . . . . . . . . . . . 17-8 5.2 register table . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-9 chapter 18: spdif input 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-1 2. functional description . . . . . . . . . . . . . . . . . 18-1 2.1 spdif input block level diagram . . . . . . . . . . 18-1 2.2 architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-2 2.2.1 functional modes . . . . . . . . . . . . . . . . . . . . . . . . 18-2 2.3 general operations . . . . . . . . . . . . . . . . . . . . . . 18-3 2.3.1 received serial format . . . . . . . . . . . . . . . . . . . 18-3 2.3.2 memory formats . . . . . . . . . . . . . . . . . . . . . . . . . 18-3 2.3.3 spdif input endian mode . . . . . . . . . . . . . . . . 18-4 2.3.4 bandwidth and latency requirements . . . . . . 18-5 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-6 3.1 clock programming . . . . . . . . . . . . . . . . . . . . . . 18-6 3.1.1 spdif input clock domains . . . . . . . . . . . . . . . 18-6 3.1.2 spdif receiver sample rate tolerance and iec60958 18-6 3.1.3 spdif input receiver jitter tolerance . . . . . . 18-6 3.1.4 spdif input and the oversampling clock . . . 18-7 3.2 register programming guidelines . . . . . . . . . 18-7 3.2.1 spdif input register set . . . . . . . . . . . . . . . . . 18-7 3.2.2 spdi_status register functions . . . . . . . . . 18-8 3.2.3 lock and unlock state behavior . . . . . . . . 18-8 3.2.4 unlock error behavior and dma . . . . . . . . . 18-8 3.2.5 spdi_ctl and functions . . . . . . . . . . . . . . . . . 18-9 3.2.6 spdi_cbitsx and channel status bits . . . . 18-10 3.2.7 spdi_ubitsx and user bits . . . . . . . . . . . . . . 18-11 3.2.8 spdi_basex and spdi_size registers and memory buffers 18-12 3.2.9 spdi_smpmask and sample size masking . 18- 12 3.2.10 spdi_bptr and the start of an iec60958 block 18-12 3.2.11 interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-13 3.2.12 event timestamping . . . . . . . . . . . . . . . . . . . . . 18-13 4. signal descriptions . . . . . . . . . . . . . . . . . . . . 18-14 4.1 external interface pins . . . . . . . . . . . . . . . . . . . 18-14 4.1.1 system interface requirements . . . . . . . . . . . 18-14 5. register descriptions . . . . . . . . . . . . . . . . . . 18-15 5.1 register summary . . . . . . . . . . . . . . . . . . . . . . 18-15 5.1.1 spdif input interrupt registers . . . . . . . . . . . 18-15 5.2 register table . . . . . . . . . . . . . . . . . . . . . . . . . . 18-17 chapter 19: memory based scaler 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-1 2. functional description . . . . . . . . . . . . . . . . . 19-2 2.1 mbs block level diagram . . . . . . . . . . . . . . . . 19-2 2.2 data flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-3 2.2.1 horizontal processing pipeline . . . . . . . . . . . . 19-3 2.2.2 vertical processing pipeline . . . . . . . . . . . . . . 19-4 2.3 data processing in mbs . . . . . . . . . . . . . . . . . . 19-5 2.4 general operations . . . . . . . . . . . . . . . . . . . . . . 19-6 2.4.1 task control . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-6 2.4.2 video source controls . . . . . . . . . . . . . . . . . . . . 19-7 2.4.3 horizontal video filters . . . . . . . . . . . . . . . . . . . 19-8 2.4.4 vertical video filters . . . . . . . . . . . . . . . . . . . . . 19-10 2.4.5 de-interlacing in mbs . . . . . . . . . . . . . . . . . . . 19-10 2.4.6 color-key processing . . . . . . . . . . . . . . . . . . . . 19-10 2.4.7 alpha processing . . . . . . . . . . . . . . . . . . . . . . . 19-11 2.4.8 video data output . . . . . . . . . . . . . . . . . . . . . . . 19-11 2.4.9 address generation . . . . . . . . . . . . . . . . . . . . . 19-12 2.4.10 interrupt generation . . . . . . . . . . . . . . . . . . . . . 19-12 2.4.11 measurement functions . . . . . . . . . . . . . . . . . 19-13 3. register descriptions . . . . . . . . . . . . . . . . . . 19-14 3.1 register summary . . . . . . . . . . . . . . . . . . . . . . 19-14 3.2 register table . . . . . . . . . . . . . . . . . . . . . . . . . . 19-16
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -9 chapter 20: 2d drawing engine 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-1 2. functional description . . . . . . . . . . . . . . . . . 20-1 2.1 2d drawing engine block level diagram . . . 20-2 2.2 architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-2 2.2.1 registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-2 2.2.2 host interface . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-2 2.2.3 color expand . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-2 2.2.4 rotator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.5 source fifo . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.6 pattern fifo . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.7 destination fifo . . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.8 write datapath . . . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.9 source state . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.10 destination state . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.11 address stepper . . . . . . . . . . . . . . . . . . . . . . . . . 20-3 2.2.12 bit blt engine . . . . . . . . . . . . . . . . . . . . . . . . . . 20-4 2.2.13 vector engine . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-4 2.2.14 memory interface . . . . . . . . . . . . . . . . . . . . . . . . 20-4 2.2.15 byte masking . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-4 2.3 general operations . . . . . . . . . . . . . . . . . . . . . . 20-4 2.3.1 raster operations . . . . . . . . . . . . . . . . . . . . . . . . 20-4 2.3.2 alpha blending . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-5 2.3.3 source data location and type . . . . . . . . . . . 20-5 2.3.4 patterns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-6 2.3.5 transparency . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-6 2.3.6 block writes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-6 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-6 3.1 register programming guidelines . . . . . . . . . . 20-6 3.1.1 alpha blending . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-6 3.1.2 mono expand . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-9 3.1.3 mono blt register setup . . . . . . . . . . . . . . . . 20-10 3.1.4 solid fill setup . . . . . . . . . . . . . . . . . . . . . . . . . . 20-11 3.1.5 color blt setup . . . . . . . . . . . . . . . . . . . . . . . . 20-11 3.1.6 patram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-12 4. register descriptions . . . . . . . . . . . . . . . . . . 20-13 4.1 register summary . . . . . . . . . . . . . . . . . . . . . . 20-14 4.2 register tables . . . . . . . . . . . . . . . . . . . . . . . . . 20-15 chapter 21: mpeg-1 and mpeg-2 variable length decoder 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-1 2. functional description . . . . . . . . . . . . . . . . . 21-3 2.1 vld block level diagram . . . . . . . . . . . . . . . . . 21-3 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-3 3.1 reset-related issues . . . . . . . . . . . . . . . . . . . . 21-3 3.2 vld mmio registers . . . . . . . . . . . . . . . . . . . . . 21-4 3.2.1 vld status (vld_mc_status) . . . . . . . . . . 21-4 3.2.2 vld interrupt enable (vld_ie) . . . . . . . . . . . . 21-5 3.2.3 vld control (vld_ctl) . . . . . . . . . . . . . . . . . . 21-5 3.2.4 vld dma current read address (vld_inp_adr) and read count (vld_inp_cnt) 21-6 3.2.5 vld dma macroblock header current write address (vld_mbh_adr) 21-6 3.2.6 vld dma macroblock header current write count 21-6 3.2.7 vld dma run-level current write address (vld_rl_adr) 21-7 3.2.8 vld dma run-level current write count . . 21-7 3.2.9 vld command (vld_command) . . . . . . . . 21-7 3.2.10 vld shift register (vld_sr) . . . . . . . . . . . . . . 21-9 3.2.11 vld quantizer scale (vld_qs) . . . . . . . . . . . 21-9 3.2.12 vld picture info (vld_pi) . . . . . . . . . . . . . . . . . 21-9 3.2.13 vld bit count (vld_bit_cnt) . . . . . . . . . . . . 21-9 3.3 vld operation . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-9 3.3.1 vld input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-10 3.3.2 vld output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-10 3.3.3 restart the vld parsing . . . . . . . . . . . . . . . . . 21-13 3.4 error handling . . . . . . . . . . . . . . . . . . . . . . . . . . 21-13 3.4.1 unexpected start code . . . . . . . . . . . . . . . . . . 21-14 3.4.2 rl overflow . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-14 3.4.3 flush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-14 4. application notes . . . . . . . . . . . . . . . . . . . . . . 21-15 4.0.1 pnx1300 series versus pnx15xx series vld 21- 15 5. register descriptions . . . . . . . . . . . . . . . . . . 21-15 5.1 pnx1300 series and pnx15xx series register differences 21-15 5.2 vld register summary . . . . . . . . . . . . . . . . . . 21-15 5.3 register table . . . . . . . . . . . . . . . . . . . . . . . . . . 21-16 chapter 22: digital video disc descrambler 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22-1 1.1 functional description . . . . . . . . . . . . . . . . . . . . 22-1 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-1 chapter 23: lan100 ?ethernet media access controller 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-1 2. functional description . . . . . . . . . . . . . . . . . 23-2 2.1 chip i/o and system interconnections . . . . . . 23-2 2.2 functional block diagram . . . . . . . . . . . . . . . . . 23-3 2.3 description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-4 3. register descriptions . . . . . . . . . . . . . . . . . . . 23-5 3.1 register summary . . . . . . . . . . . . . . . . . . . . . . . 23-5 3.2 register definitions . . . . . . . . . . . . . . . . . . . . . . . 23-8
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -10 3.3 pattern matching join register . . . . . . . . . . . 23-25 4. descriptor and status formats . . . . . . . . 23-27 4.1 receive descriptors and status . . . . . . . . . . 23-27 4.2 transmit descriptors and status . . . . . . . . . . 23-30 5. lan100 functions . . . . . . . . . . . . . . . . . . . . . 23-33 5.1 mmio interface . . . . . . . . . . . . . . . . . . . . . . . . . 23-33 5.1.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-33 5.2 direct memory access . . . . . . . . . . . . . . . . . . . 23-34 5.2.1 descriptor fifos . . . . . . . . . . . . . . . . . . . . . . . 23-34 5.2.2 ownership of descriptors . . . . . . . . . . . . . . . . 23-34 5.2.3 sequential order with wrap-around . . . . . . . 23-35 5.2.4 full and empty state of fifos . . . . . . . . . . . . 23-35 5.2.5 interrupt bit . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-36 5.2.6 packet fragments . . . . . . . . . . . . . . . . . . . . . . 23-36 5.3 initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-37 5.4 transmit process . . . . . . . . . . . . . . . . . . . . . . . 23-38 5.4.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-38 5.4.2 device driver sets up descriptors and data 23-38 5.4.3 tx(rt) dma manager reads tx(rt) descriptor arrays 23-39 5.4.4 tx(rt) dma manager transmits data . . . . . . 23-39 5.4.5 update consumeindex . . . . . . . . . . . . . . . . . . 23-40 5.4.6 write transmission status . . . . . . . . . . . . . . . 23-40 5.4.7 transmission error handling . . . . . . . . . . . . . 23-40 5.4.8 transmit triggers interrupts . . . . . . . . . . . . . . 23-41 5.4.9 transmit example . . . . . . . . . . . . . . . . . . . . . . . 23-42 5.5 receive process . . . . . . . . . . . . . . . . . . . . . . . . 23-45 5.5.1 device driver sets up descriptors . . . . . . . . 23-46 5.5.2 rx dma manager reads rx descriptor arrays . . 23-46 5.5.3 rx dma manager receives data . . . . . . . . . 23-46 5.5.4 update produceindex . . . . . . . . . . . . . . . . . . . 23-47 5.5.5 write reception status . . . . . . . . . . . . . . . . . . 23-47 5.5.6 reception error handling . . . . . . . . . . . . . . . . 23-47 5.5.7 receive triggers interrupts . . . . . . . . . . . . . . 23-48 5.5.8 device driver processes receive data . . . . 23-49 5.5.9 receive example . . . . . . . . . . . . . . . . . . . . . . . 23-49 5.6 transmission retry . . . . . . . . . . . . . . . . . . . . . 23-53 5.7 time-stamps . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-53 5.8 transmission modes . . . . . . . . . . . . . . . . . . . . 23-53 5.8.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-53 5.8.2 real-time/non-real-time transmission mode 23-54 5.8.3 quality-of-service transmission mode . . . . . 23-57 5.9 duplex modes . . . . . . . . . . . . . . . . . . . . . . . . . . 23-58 5.10 ieee 802.3/clause 31 flow control . . . . . . . 23-59 5.10.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-59 5.10.2 receive flow control . . . . . . . . . . . . . . . . . . . . 23-59 5.10.3 transmit flow control . . . . . . . . . . . . . . . . . . . 23-59 5.11 half-duplex mode back pressure . . . . . . . . . . 23-61 5.12 receive filtering . . . . . . . . . . . . . . . . . . . . . . . . . 23-62 5.12.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-62 5.12.2 unicast, broadcast and multicast . . . . . . . . . . 23-64 5.12.3 perfect address match . . . . . . . . . . . . . . . . . . . 23-64 5.12.4 imperfect hash filtering . . . . . . . . . . . . . . . . . . 23-64 5.12.5 pattern match filtering and logic functions 23-65 5.12.6 enabling and disabling filtering . . . . . . . . . . . 23-66 5.12.7 runt frames . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-66 5.13 wake-up on lan . . . . . . . . . . . . . . . . . . . . . . . . 23-66 5.13.1 overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-66 5.13.2 filtering for wol . . . . . . . . . . . . . . . . . . . . . . . . 23-67 5.13.3 magic packet wol . . . . . . . . . . . . . . . . . . . . . . 23-67 5.14 enabling and disabling receive and transmit 23- 68 5.14.1 enabling and disabling reception . . . . . . . . . 23-68 5.14.2 enabling and disabling transmission . . . . . . 23-69 5.15 transmission padding and crc . . . . . . . . . . 23-69 5.16 huge frames and frame length checking . 23-70 5.17 statistics counters . . . . . . . . . . . . . . . . . . . . . . 23-71 5.18 status vectors . . . . . . . . . . . . . . . . . . . . . . . . . . 23-71 5.19 reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-71 5.19.1 hard reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-71 5.19.2 soft reset . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-71 6. system integration . . . . . . . . . . . . . . . . . . . . . 23-73 6.1 mii interface i/o . . . . . . . . . . . . . . . . . . . . . . . . . 23-73 6.2 power management . . . . . . . . . . . . . . . . . . . . . 23-74 6.2.1 sleep mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-74 6.2.2 coma mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-74 6.3 disabling the lan100 . . . . . . . . . . . . . . . . . . . . 23-75 6.4 little/big endian . . . . . . . . . . . . . . . . . . . . . . . . . 23-75 6.5 interrupts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-75 6.6 errors and aborts . . . . . . . . . . . . . . . . . . . . . . . 23-75 6.7 cache coherency . . . . . . . . . . . . . . . . . . . . . . . 23-76 chapter 24: tm3260 debug 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-1 2. functional description . . . . . . . . . . . . . . . . . 24-1 2.1 general operations . . . . . . . . . . . . . . . . . . . . . . 24-1 2.1.1 test access port (tap) . . . . . . . . . . . . . . . . . . . 24-1 2.1.2 tap controller . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-2 2.1.3 pnx15xx series jtag instruction set . . . . . . 24-4 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-4 3.1 register programming guidelines . . . . . . . . . . 24-4 3.1.1 handshaking and communication protocol . . 24-5 3.2 debug settings . . . . . . . . . . . . . . . . . . . . . . . . . . 24-6 4. register descriptions . . . . . . . . . . . . . . . . . . . 24-7 4.1 register summary . . . . . . . . . . . . . . . . . . . . . . . 24-9 chapter 25: i 2 c interface 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-2 2. functional description . . . . . . . . . . . . . . . . . 25-2 2.1 general operations . . . . . . . . . . . . . . . . . . . . . . 25-2 2.1.1 iic arbitration and control logic . . . . . . . . . . . 25-2 2.1.2 serial clock generator . . . . . . . . . . . . . . . . . . . . 25-3
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -11 2.1.3 bit counter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-3 2.1.4 control register . . . . . . . . . . . . . . . . . . . . . . . . . 25-3 2.1.5 status decoder and register . . . . . . . . . . . . . . 25-3 2.1.6 input filter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-3 2.1.7 address register and comparator . . . . . . . . . 25-3 2.1.8 data shift register . . . . . . . . . . . . . . . . . . . . . . . 25-4 2.1.9 related interrupts . . . . . . . . . . . . . . . . . . . . . . . . 25-4 2.1.10 modes of operation . . . . . . . . . . . . . . . . . . . . . . 25-4 3. register descriptions . . . . . . . . . . . . . . . . . . . 25-7 3.1 register tables . . . . . . . . . . . . . . . . . . . . . . . . . . 25-8 chapter 26: memory arbiter 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-1 2. functional description . . . . . . . . . . . . . . . . . 26-1 2.1 arbiter features . . . . . . . . . . . . . . . . . . . . . . . . . 26-2 2.2 id mapping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-2 2.2.1 dcs gate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-3 2.3 arbitration algorithm . . . . . . . . . . . . . . . . . . . . . 26-3 2.3.1 arbiter startup behavior . . . . . . . . . . . . . . . . . . . 26-6 3. operation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-6 3.1 clock programming . . . . . . . . . . . . . . . . . . . . . . 26-6 3.2 register programming guidelines . . . . . . . . . . 26-6 4. register descriptions . . . . . . . . . . . . . . . . . . . 26-7 4.1 register table . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-7 chapter 27: power management 1. power management mechanisms . . . . . . . 27-1 1.1 clock management . . . . . . . . . . . . . . . . . . . . . . 27-1 1.1.1 essential operating infrastructure during powerdown 27-1 1.1.2 module powerdown sequence . . . . . . . . . . . . . 27-1 1.1.3 peripheral module wakeup sequence . . . . . . 27-2 1.1.4 tm3260 powerdown modes . . . . . . . . . . . . . . . 27-2 1.1.5 sdram controller . . . . . . . . . . . . . . . . . . . . . . . . 27-3 chapter 28: pixel formats 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-1 2. summary of native pixel formats . . . . . . 28-2 3. native pixel format representation . . . . 28-3 3.1 indexed formats . . . . . . . . . . . . . . . . . . . . . . . . . 28-3 3.2 16-bit pixel-packed formats . . . . . . . . . . . . . . 28-4 3.3 32-bit pixel-packed formats . . . . . . . . . . . . . . 28-4 3.4 packed yuv 4:2:2 formats . . . . . . . . . . . . . . . 28-5 3.5 planar yuv 4:2:0 and yuv 4:2:2 formats . . 28-6 3.5.1 planar variants . . . . . . . . . . . . . . . . . . . . . . . . . . 28-6 3.5.2 semi-planar 10-bit yuv 4:2:2 and 4:2:0 formats 28-9 3.5.3 packed 10-bit yuv 4:2:2 format . . . . . . . . . . . 28-10 4. universal converter . . . . . . . . . . . . . . . . . . . . 28-10 5. alpha value and pixel transparency . . . 28-11 6. rgb and yuv values . . . . . . . . . . . . . . . . . . 28-11 7. image storage format . . . . . . . . . . . . . . . . . 28-11 8. system endian mode . . . . . . . . . . . . . . . . . . 28-12 chapter 29: endian mode 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-1 1.1 features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-1 2. functional description . . . . . . . . . . . . . . . . . 29-2 2.1 endian mode system block diagram . . . . . . . 29-2 3. endian mode theory . . . . . . . . . . . . . . . . . . . 29-4 3.1 law 1: the ?pu rule . . . . . . . . . . . . . . . . . . . 29-4 3.2 law 2: the ?ma convention rule . . . . . . . . 29-6 4. pnx15xx series endian mode architecture details 29-7 4.1 global endian mode . . . . . . . . . . . . . . . . . . . . . 29-7 4.2 module control . . . . . . . . . . . . . . . . . . . . . . . . . . 29-7 4.3 module dma . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-8 4.4 simd programming issues . . . . . . . . . . . . . . . . 29-8 4.5 optional endian mode override . . . . . . . . . . . 29-8 5. example: audio in?rogrammers view 29- 9 6. implementation details . . . . . . . . . . . . . . . . 29-10 6.1 pman network endian block diagram . . . . . 29-10 6.2 dma across a dtl interface . . . . . . . . . . . . . 29-11 6.2.1 dtl data ordering rules . . . . . . . . . . . . . . . . 29-11 6.2.2 address invariant data ordering rules . . . . 29-12 6.3 data transfers across the dcs network . . . 29-12 6.4 dma across the mtl bus . . . . . . . . . . . . . . . . 29-13 6.5 dtl-to-mtl adapters . . . . . . . . . . . . . . . . . . . . 29-14 6.6 pci interface . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-14 7. detailed example . . . . . . . . . . . . . . . . . . . . . . 29-15 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-1 chapter 30: dcs network 2. functional description . . . . . . . . . . . . . . . . . 30-1 2.1 error generation . . . . . . . . . . . . . . . . . . . . . . . . . 30-2 2.2 interrupt generation . . . . . . . . . . . . . . . . . . . . . . 30-2
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -12 2.3 programmable timeout . . . . . . . . . . . . . . . . . . . 30-2 2.3.1 arbitration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-2 2.4 endian mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-3 3. register descriptions . . . . . . . . . . . . . . . . . . 30-3 3.1 register summary . . . . . . . . . . . . . . . . . . . . . . . 30-3 3.2 register tables . . . . . . . . . . . . . . . . . . . . . . . . . . 30-4 chapter 31: tm3260 1. introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31-1 1 data sheet status . . . . . . . . . . . . . . . . . . . . . . . . . . 3 2. de?itions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 3. disclaimers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 4. licenses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 5. trademarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 6. contact information . . . . . . . . . . . . . . . . . . . . . . . 3
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -13
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -14 chapter 1: integrated circuit data figure 1: application diagram of the crystal oscillator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-23 figure 2: sstl_2 test load condition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-24 figure 3: sstl_2 receiver signal conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-24 figure 4: bpx2t14mcp test load condition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-25 figure 5: bpts1chp and bpts1cp test load condition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-26 figure 6: bpts3chp test load condition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-27 figure 7: bpt3mchdt5v and bpt3mcht5v test load condition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28 figure 8: pci tval(min) and slew rate test load condition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-29 figure 9: reset timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-30 figure 10: pci output and input timing measurement conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-32 figure 11: pci tval(max) rising and falling edge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-32 figure 12: qvcp and fgpo i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-33 figure 13: vip and fgpi i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-34 figure 14: lan 10/100 i/o timing in mii mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-35 figure 15: lan 10/100 i/o timing in rmii mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-36 figure 16: audio input i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-37 figure 17: audio output i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-38 figure 18: spdif i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-38 figure 19: i2c i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-39 figure 20: i2c i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-40 figure 21: audio output i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-41 figure 22: jtag i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-41 figure 23: bga456 plastic ball grid array; 456 balls; body 27 x 27 x 1.75 mm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-42 figure 24: digital vccp power supply to analog vcca/vssa power supply filter . . . . . . . . . . . . . . . . . . . . . . . . . 1-44 figure 25: digital vdd power supply to analog vdda/vssa_1.2 power supply filter . . . . . . . . . . . . . . . . . . . . . . . 1-44 figure 26: digital vdd power supply to analog vdda/vssa_1.2 power supply filter . . . . . . . . . . . . . . . . . . . . . . . 1-45 chapter 2: overview figure 1: block diagram pnx15xx series . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1 figure 2: pnx15xx series functional block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-5 chapter 3: system on chip resources figure 1: the two operating modes of pnx15xx series . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-1 figure 2: pnx15xx series system memory map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-4 figure 3: simplified internal bus infrastructure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-30 chapter 4: reset figure 1: reset module block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-3 figure 2: watchdog in non interrupt mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-5 figure 3: watchdog in interrupt mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-6 figure 4: por_in_n timing and reset sequence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-7 chapter 5: the clock module figure 1: clock module block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-3 figure 2: pll block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-8 figure 3: block diagram of the clock control logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-13 figure 4: waveforms of the blocking logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-14 figure 5: clock stretcher . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-16 figure 6: clock detection circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-18
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -15 figure 7: tm3260, ddr and qvcp clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-21 figure 8: qvcp_proc clock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-22 figure 9: qvcp_pix clock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-22 figure 10: clock dividers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-23 figure 11: internal pnx15xx series clock from dividers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-24 figure 12: internal pnx15xx series clock from dividers: pci, spdi, lcd and i2c . . . . . . . . . . . . . . . . . . . . . . . . . . 5-25 figure 13: internal pnx15xx series clock from dividers: lcd timestamp . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-25 figure 14: gpio clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-26 figure 15: vdi_clk1 block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-27 figure 16: vdi_clk2 block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-27 figure 17: vdo_clk1 block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-28 figure 18: vdo_clk2 block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-28 figure 19: ao clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-29 figure 20: ai clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-29 figure 21: phy lan clock block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-30 figure 22: receive and transmit lan clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-30 figure 23: spdo clock . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-31 chapter 6: boot module figure 1: boot block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-4 figure 2: system memory map and block diagram configuration for pnx15xx series in standalone mode . . . . 6-10 figure 3: system memory map and block diagram configuration for pnx15xx series in host-assisted mode . . 6-13 chapter 7: pci-xio module figure 1: document title variable block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3 figure 2: read status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-7 figure 3: read data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-8 figure 4: write data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-9 figure 5: block erase . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-9 figure 6: motorola write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-10 figure 7: motorola read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-11 figure 8: nor flash write . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-12 figure 9: nor flash read . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-12 figure 10: ide interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-13 figure 11: isolation translation logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-14 figure 12: register transfer/pio data transfer on ide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-16 figure 13: timings on ide bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-17 figure 14: ide transaction, flow controlled by device iordy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-17 chapter 8: general purpose input output pins figure 1: gpio module block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-2 figure 2: functional block diagram of a gpio pin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-4 figure 3: 32-bit timestamp format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-7 figure 4: 1-bit signal sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-10 figure 5: up to 4-bit signal sampling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-11 figure 6: 1-bit pattern generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-13 figure 7: up to 4-bit samples per fifo in pattern generation mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-14 figure 8: example of ir tx signals with and without sub-carrier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-19 figure 9: irda control tx with sub-carrier enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-19 figure 10: sub-carrier multiplexing for tx . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-19 figure 11: examples of duty cycles for ir tx signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-20
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -16 chapter 9: ddr controller figure 1: the two mtl ports of the ddr sdram controller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-3 figure 2: arbitration in the ddr controller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-3 figure 3: cpu account . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-5 figure 4: arbitration when dma has priority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-6 figure 5: cpu account using dynamic ratios . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-7 figure 6: address mapping: interleaved mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-10 figure 7: ddr sdram controller start and halt state machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-15 figure 8: examples of supported memory configurations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-17 figure 9: tcas timing parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-21 figure 10: trrd and trc timing parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-21 figure 11: trfc timing parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-21 figure 12: twr timing parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-22 figure 13: tras timing parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-22 figure 14: trp timing parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-22 figure 15: trcd_rd timing parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-23 figure 16: trcd_wr timing parameter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-23 chapter 10: lcd controller figure 1: block diagram of the lcd controller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-2 figure 2: generic power sequence for tft lcd panels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-2 figure 3: power sequencing state machine block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-4 figure 4: clock gating logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-5 chapter 11: qvcp figure 1: qvcp top level diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-2 figure 2: qvcp block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-4 figure 3: undithering and pedestal manipulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-10 figure 4: 4:2:2 and 4:4:4 formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-11 figure 5: mixer block diagram?ixel selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-18 figure 6: mixer block diagram?ixel processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-19 figure 7: vbi/programming data packet formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-24 figure 8: shadow mechanism . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-27 figure 9: shadowing of registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-28 figure 10: resource layer and id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-31 figure 11: resource layer and id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-32 figure 12: 2-layer 1 resource elements scenario . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-32 figure 13: pool and aperture reassignments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-34 figure 14: video frame screen timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1-35 chapter 12: video input processor figure 1: simplified vip block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 2-2 figure 2: vip module interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-3 figure 3: digital video input port timing relationships in hd mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-4 figure 4: test pattern . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-5 figure 5: d1 data stream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-6 figure 6: hd dual data stream . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-7 figure 7: video data flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-8 figure 8: source and target window parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-9 figure 9: acquisition window counter reference . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-9 figure 10: field identifier timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-10
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -17 figure 11: double buffer mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-14 figure 12: auxiliary data flow . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-15 figure 13: anc data structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-16 figure 14: anc masked id checking . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-17 chapter 13: fgpo: fast general purpose output figure 1: top level block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-2 figure 2: fgpo module block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 3-2 figure 3: back-to-back message passing example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-9 figure 4: double buffer major states . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-11 figure 5: signal edge definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-12 figure 6: back-to-back message passing example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-13 chapter 14: fgpi: fast general purpose interface figure 1: top level block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-2 figure 2: fgpi module block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-3 figure 3: input data width not equal to sample size setting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-7 figure 4: double buffer major states . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-11 figure 5: buffer sync actions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-12 figure 6: signal edge definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-13 figure 7: back-to-back message passing example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-14 chapter 15: audio output figure 1: audio out block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-2 figure 2: examples of audio out memory dma formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-4 figure 3: definition of serial frame bit positions (polarity = 1, clock_edge = 0) . . . . . . . . . . . . . . . . . . . . . 15-7 figure 4: serial frame (64 bits) of a 18-bit precision i 2 s d/a converter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-8 figure 5: example codec frame layout for a crystal semiconductor cs4218 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-10 figure 6: audio out clock system and i/o interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-12 chapter 16: audio input figure 1: audio in block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-2 figure 2: audio in clock system and i/o interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-5 figure 3: audio in serial frame and bit position definition (polarity = 1, clock_edge = 0, earlymode = 0) 16-8 figure 4: audio in serial frame and bit position definition (polarity = 1, clock_edge = 0, earlymode = 1) 16-8 figure 5: serial frame of the saa7366 18-bit i2s a/d converter (format 2 sws) . . . . . . . . . . . . . . . . . . . . . . . . . 16-9 figure 6: audio in memory dma formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-10 chapter 17: spdif output figure 1: serial format of a iec-60958 block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-4 figure 2: bi-phase mark data transmission . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-5 figure 3: suggested external spdif output interface circuitry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-8 chapter 18: spdif input figure 1: spdif input block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-2 figure 2: serial format of an iec60958 block . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-3 figure 3: spdif input: raw mode format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-4 figure 4: spdif input sample order view of memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-4 figure 5: endian mode byte address memory format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-5
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -18 figure 6: spdif input oversampling clock generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-7 figure 7: lock/unlock processing for spdif input . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-9 figure 8: spdif input consumer interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-14 figure 9: spdif input mmio registers (1 of 2) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-15 figure 10: spdif input mmio registers (2 of 2) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-16 chapter 19: memory based scaler figure 1: mbs block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-2 figure 2: mbs top level . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-3 figure 3: mbs horizontal processing pipeline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-3 figure 4: mbs vertical processing pipeline . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-4 figure 5: task fifo and linked list . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-6 figure 6: measurement in the mbs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-13 chapter 20: 2d drawing engine figure 1: 2d drawing engine block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-2 chapter 21: mpeg-1 and mpeg-2 variable length decoder figure 1: vld block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-3 figure 2: mpeg-2 macro block header output format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-11 figure 3: mpeg-1 macro block header output format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-12 chapter 22: digital video disc descrambler chapter 23: lan100 ?ethernet media access controller figure 1: simplified lan100 i/o block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-2 figure 2: lan100 functional block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-3 figure 3: pattern matching join function . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23- 26 figure 4: receive descriptor memory layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-27 figure 5: transmit descriptor memory layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-30 figure 6: transmit example memory and registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-42 figure 7: transmit example waves . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-45 figure 8: receive example memory and registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-49 figure 9: receive example waves . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-52 figure 10: real-time/non-real-time transmit example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-56 figure 11: qos transmission example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-58 figure 12: transmit flow control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-61 figure 13: receive filter block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-63 figure 14: receive active/inactive state machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-68 figure 15: transmit active/inactive state machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-69 chapter 24: tm3260 debug figure 1: state diagram of tap controller . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-3 figure 2: system with jtag access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-6 figure 3: additional jtag data and control registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-8 chapter 25: i 2 c interface figure 1: sda first transmitted byte . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-5
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -19 chapter 26: memory arbiter figure 1: arbitration scheme . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-4 chapter 27: power management chapter 28: pixel formats figure 1: native pixel format unit layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-3 figure 2: indexed formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-4 figure 3: 16-bit pixel-packed formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-4 figure 4: 32-bit/pixel packed formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-5 figure 5: uyvy packed yuv 4:2:2 format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-5 figure 6: yuy2/2vuy packed yuv 4:2:2 format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-6 figure 7: spatial sampling structure of packed and planar yuv 4:2:2 data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-6 figure 8: spatial sampling structure of yuv 4:2:0 data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-6 figure 9: planar yuv 4:2:0 and 4:2:2 formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-7 figure 10: semi-planar yuv 4:2:0 and yuv 4:2:2 formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-8 figure 11: semi-planar 10-bit yuv 4:2:0 and yuv 4:2:2 formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-9 figure 12: packed 10-bit yuv 4:2:2 format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-10 figure 13: image storage format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-12 chapter 29: endian mode figure 1: system block diagram: endian-related blocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-3 figure 2: big-endian layout of dma_descriptor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-4 figure 3: little-endian layout of dma_descriptor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-5 figure 4: memory content created by the c program . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-6 figure 5: audio in memory data structure (programmer? view) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-9 figure 6: audio in control/status mmio registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-10 figure 7: big-endian external cpu drawing two rgb-565 pixels . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-16 chapter 30: dcs network chapter 31: tm3260
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -20 chapter 1: integrated circuit data table 1: pnx1500 i/o types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 table 2: pnx1500 i/o modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-2 table 3: pnx1500 special i/os . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-3 table 4: pnx1500 interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-3 table 5: power pin list . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-18 table 6: pin reference voltage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-19 table 7: absolute maximum ratings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-20 table 8: operating range and thermal characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-20 table 9: maximum operating speeds based on the vdd power supply for the pnx1501 . . . . . . . . . . . . . . . . . . 1-21 table 10: maximum operating speeds based on the vdd power supply for the pnx1502 . . . . . . . . . . . . . . . . . . 1-21 table 11: mpeg-2 decoding with 720x480p output on pnx1501 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-22 table 12: mpeg-2 decoding with 720x480p output on pnx1502 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-22 table 13: estimated pnx1501 maximum and peak current . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-22 table 14: estimated pnx1502 maximum and peak current . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-22 table 15: specification of hc-49u 27.00000 mhz crystal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-23 table 16: sstl_2 ac/dc characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-23 table 17: bpx2t14mcp characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1- 25 table 18: bpts1chp and bpts1cp characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-26 table 19: bpts3chp characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-27 table 20: ipchp and ipcp characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28 table 21: bpt3mchdt5v and bpt3mcht5v characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-28 table 22: iic3m4sdat5v and iic3m4sclt5v characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-29 table 23: pcit5v characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-29 table 24: reset timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-30 table 25: ddr dram interface timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-30 table 26: pci bus timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-31 table 27: qvcp, lcd and fgpo timing with internal clock generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-33 table 28: qvcp, lcd and fgpo timing with external clock generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-33 table 29: vip and fgpi timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-34 table 30: 10/100 lan mii timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-34 table 31: 10/100 lan rmii timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-35 table 32: audio input timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-36 table 33: audio output timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-37 table 34: spdif i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-38 table 35: i2c i/o timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-39 table 36: gpio timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-40 table 37: jtag timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-41 table 38: ddr recommended trance length . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-45 table 39: ordering information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-47 chapter 2: overview table 1: partitioning of functions to resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-2 table 2: pnx15xx series boot options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-6 table 3: footprints for 32-bit and 16-bit ddr interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-9 table 4: tm3260 characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-11 table 5: native pixel format summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2- 13 table 6: video/data input operating modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-19 table 7: video/data output operating modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-20 table 8: pnx15xx series pci capabilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-24 table 9: pci/xio-16 bus interface unit capabilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-25
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -21 chapter 3: system on chip resources table 1: system registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-6 table 2: system registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-8 table 3: system registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-9 table 4: semaphore mmio registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-11 table 5: interrupt source assignments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 -12 table 6: tm3260 timer source selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-14 table 7: tm3260 system parameters mmio registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-16 table 8: global registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-18 table 9: miscellaneous system mmio registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-27 table 10: system registers map summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-29 table 11: mmio memory map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-31 chapter 4: reset table 1: reset module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4-9 chapter 5: the clock module table 1: pnx15xx series module and bus clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-4 table 2: current adjustment values based on n . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-9 table 3: pll setting examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-9 table 4: pll characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-10 table 5: internal clock dividers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-10 table 6: dds and pll clock assignment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-11 table 7: external clocks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-11 table 8: bypass clock sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-14 table 9: advantages of centralized clock gating control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-17 table 10: registers summar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-31 table 11: clock module registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-34 chapter 6: boot module table 1: the boot modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-2 table 2: the boot commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-6 table 3: default ddr sdram timing parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-7 table 4: cas latency related ddr sdram timing parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-7 table 5: pci setup and pci command register content . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-8 table 6: binary sequence for the common boot script . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-9 table 7: flash timing parameters used by the default boot scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-11 table 8: binary sequence for the section of the flash boot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-12 table 9: host configuration sequence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 -13 table 10: examples of i2c eeprom devices . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-14 chapter 7: pci-xio module table 1: supported pci commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-3 table 2: xio pin multiplexing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-4 table 3: recommended settings for nand . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-6 table 4: gpxio address configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7- 15 table 5: ide timing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-16 table 6: pci-xio register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-21 table 7: pci configuration register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-22 table 8: registers description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-23
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -22 table 9: pci configuration registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7-43 chapter 8: general purpose input output pins table 1: gpio pin list . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-3 table 2: gpio mode select . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-4 table 3: settings for mask[xx] and iod[xx] bits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-5 table 4: gpio clock sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-17 table 5: example of ir characteristics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 -18 table 6: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-21 table 7: gpio mode control registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8- 24 table 8: gpio data control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-26 table 9: readable internal pnx1500 signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-26 table 10: sampling and pattern generation control registers for the fifo queues . . . . . . . . . . . . . . . . . . . . . . . . 8-27 table 11: signal and event monitoring control registers for the timestamp units . . . . . . . . . . . . . . . . . . . . . . . . . . 8-34 table 12: timestamp unit registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-34 table 13: gpio time counter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-34 table 14: gpio tm3260 timer input select . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-35 table 15: gpio interrupt status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-35 table 16: clock out select . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-36 table 17: gpio interrupt registers for the fifo queues (one for each fifo queue) . . . . . . . . . . . . . . . . . . . . . . . 8-37 table 18: gpio module status register for all 12 timestamp units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-38 table 19: gpio powerdown . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-43 table 20: gpio module id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-43 table 21: gpio io_sel selection values . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-43 chapter 9: ddr controller table 1: cpu preemption field . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-8 table 2: 32-byte interleaving, 256 columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-11 table 3: 32-byte interleaving, 512 columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-11 table 4: mapping scheme: 1024-byte interleaving, 256 columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-11 table 5: 1024-byte interleaving, 512 columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-12 table 6: ddr timing parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-20 table 7: ddr commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-20 table 8: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-24 table 9: register description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9-25 chapter 10: lcd controller table 1: lcd controller register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10-6 table 2: lcd controller registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10- 7 chapter 11: qvcp table 1: summary of native pixel formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-7 table 2: color key combining rops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-8 table 3: chroma key rop examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-9 table 4: rop table for invert/select/alpha/keypass/alphapass rops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-17 table 5: data packet descriptor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-23 table 6: shadow registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-28 table 7: fast access registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-29 table 8: resource id assignment . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-30 table 9: register space allocation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-31 table 10: rn association . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-31
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -23 table 11: resource-layer assignment for pool resource . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-32 table 12: programming values for supported pnx15xx series output formats . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-37 table 13: lint programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-38 table 14: hsru programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-38 table 15: lshr programming parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-39 table 16: dcti programming parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-40 table 17: cftr programming parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-40 table 18: interface characteristics for some target resolutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-42 table 19: register module association . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1-43 table 20: qvcp 1 registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11-46 chapter 12: video input processor table 1: vip submodule descriptions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-2 table 2: test pattern generator setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 2-5 table 3: video input formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-7 table 4: relationship between input formats and video data capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-8 table 5: field identifier generation modes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-10 table 6: output pixel formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-13 table 7: relationship between input formats and data capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-15 table 8: relationship between input formats and data capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-19 table 9: vip mmio register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12- 19 table 10: video input processor (vip) 1 registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12-21 chapter 13: fgpo: fast general purpose output table 1: module signal pins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-5 table 2: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-15 table 3: fast general purpose output (fgpo) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-15 table 4: status registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13-21 chapter 14: fgpi: fast general purpose interface table 1: module signal pins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-6 table 2: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-18 table 3: fast general purpose input (fgpi) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-18 table 4: status registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14-22 chapter 15: audio output table 1: audio out unit external signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-3 table 2: operating modes and memory formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-4 table 3: bits transmitted for each memory data item . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-7 table 4: minimum serial frame length in bits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-8 table 5: example setup for 64-bit i2s framing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-9 table 6: audio out latency tolerance examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-11 table 7: clock system setting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-13 table 8: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15-15 table 9: audio output port registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 5-15 chapter 16: audio input table 1: audio-in i2s related ports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-3 table 2: sample rate settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-6 table 3: bit positions assigned for each data item . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-9
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -24 table 4: example setup for saa7366 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 6-9 table 5: operating modes and memory formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-10 table 6: endian ordering of audio data in main memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-10 table 7: audio in data bus arbiter latency requirement examples ?16-bit data examples . . . . . . . . . . . . . . 16-12 table 8: audio in data bus arbiter latency requirement examples ?32-bit data examples . . . . . . . . . . . . . . 16-12 table 9: raw mode format of input data and word select . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-15 table 10: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-15 table 11: audio (i 2 s) input ports registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16-15 chapter 17: spdif output table 1: spdif out sample rates and jitter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-2 table 2: spdif subframe descriptor word . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-6 table 3: spdo block latency requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-7 table 4: spdif out external signals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-8 table 5: spdif output module register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-8 table 6: spdo registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17-9 chapter 18: spdif input table 1: spdif input oversampling clock value settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-6 table 2: input jitter for different sample rates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-7 table 3: spdi_cbits1 channel status meaning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-10 table 4: spdi_cbits2 channel status meaning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-11 table 5: spdif input pin summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-14 table 6: spdif input registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18-17 chapter 19: memory based scaler table 1: pipeline processing (horizontal first mode) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-5 table 2: pipeline processing (vertical first mode) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-5 table 3: de-interlacing mode maximum filter lengths . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-5 table 4: task descriptor opcode table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19- 7 table 5: input pixel formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-8 table 6: output pixel formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-11 table 7: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-14 table 8: memory based scaler (mbs) registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19-16 chapter 20: 2d drawing engine table 1: source and destination data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-5 table 2: mono bitmap & text data parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-10 table 3: solid color fill parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-11 table 4: color blt parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-11 table 5: 2de memory space addresses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-14 table 6: 2d command registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-14 table 7: 2d real time drawing registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-15 table 8: registers description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-15 table 9: destination address base . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-16 table 10: pixel size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-17 table 11: pixel format bit assignments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20- 17 table 12: dithering . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-18 table 13: source linear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-18 table 14: destination linear . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-18 table 15: source stride . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-19
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -25 table 16: destination stride . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-19 table 17: color compare . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-20 table 18: mono host f color or surfalpha . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-21 table 19: mono host b color or halpha color . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-21 table 20: blt control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-22 table 21: source address, xy coordinates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-23 table 22: destination address, xy coordinates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-24 table 23: blt size . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-24 table 24: destination address, xy2 coordinates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-25 table 25: vector constant . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-25 table 26: vector count control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-26 table 27: transmask . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-26 table 28: monopatfcolor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-27 table 29: monopatbcolor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-27 table 30: enginestatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-28 table 31: paniccontrol . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-29 table 32: engineconfig . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-29 table 33: hostfifostatus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-30 table 34: powerdown . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-31 table 35: module id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-31 table 36: drawing engine data registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 20-31 chapter 21: mpeg-1 and mpeg-2 variable length decoder table 1: software reset procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-4 table 2: vld status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-5 table 3: vld control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-6 table 4: vld commands . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-8 table 5: vld command register . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-9 table 6: references for the mpeg-2 macroblock header data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-11 table 7: references for the mpeg-1 macroblock header data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-13 table 8: vld error handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-14 table 9: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-15 table 10: vld registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21-16 chapter 22: digital video disc descrambler chapter 23: lan100 ?ethernet media access controller table 1: lan100 mmio register map . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-6 table 2: lan100 registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-9 table 3: patternmatchjoin register nibble functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-26 table 4: receive descriptor structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 -28 table 5: receive descriptor control word . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-28 table 6: receive status structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-29 table 7: receive status information word . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-29 table 8: transmit descriptor fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-31 table 9: transmit descriptor control word . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-32 table 10: transmit status structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-32 table 11: transmit status information word . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-33 table 12: lan100 pin interface to external phy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23-73
philips semiconductors pnx15xx series volume 1 of 1 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 -26 chapter 24: tm3260 debug table 1: jtag tm3260 instruction encoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-4 table 2: jtag instruction encoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-4 table 3: transfer of data in via jtag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-6 table 4: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-9 table 5: tm_dbg 1 registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24-10 chapter 25: i 2 c interface table 1: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-7 table 2: iic registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-8 table 3: iic registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-10 table 4: iic registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-11 table 5: status codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-11 table 6: iic registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-16 table 7: iic registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25-17 chapter 26: memory arbiter table 1: peripheral id and sub-arbitration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-2 table 2: register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26-7 table 3: pman (hub) arbiter registers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 -7 chapter 27: power management chapter 28: pixel formats table 1: native pixel format summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 -2 table 2: alpha code value and pixel transparency . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28-11 chapter 29: endian mode table 1: memory result of a store to address ??instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-5 table 2: register result of an (unsigned) load instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-5 table 3: register result of a (signed) load instruction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-6 table 4: precise mapping audio in sample time and bits to memory bytes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-9 table 5: dtl interface rules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-11 table 6: 32 bit dtl interface byte address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-12 table 7: dtl interface rules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-12 table 8: dcs network data transfer rules (32 bits at-a-time transfer) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-12 table 9: mtl memory bus byte address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-13 table 10: mtl memory bus item dma rules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-13 table 11: 32 bit pci interface byte address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29-15 chapter 30: dcs network table 1: dcs controller_trimedia configuration register summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-3 table 2: dcs controller_trimedia configuration registers (rev 0.32) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 30-4 chapter 31: tm3260
1. introduction the pnx1500 media processor series is a complete audio/video/graphics system on a chip that contains a high-performance 32-bit vliw processor, trimedia ? tm3260, capable of high quality software video (multi-video standard digital decoder/ encoder and image improvement), audio signal processing, as well as general purpose control processing. it can either be used in standalone, or as an accelerator to a general purpose processor. the pnx1500 processes the input signals by utilizing several audio/video and co-processor modules before send them to the external peripherals. these modules provide additional video and data processing bandwidth without taking away precious cpu cycles. the combination of the cpu and co-processor modules makes the pnx1500 system on-chip suitable for most applications, especially those requiring high level of processing power/throughput at a reduced cost. refer to section 13. on page 1- 47 for ordering information as well as for the different pnx1500 derivatives available. throughout this document pnx1500 or pnx15xx series will be used to refer to any of the derivatives of pnx1500 devices unless otherwise speci?d. 2. pin description 2.1 boundary scan notice pnx1500 implements full ieee1149.1 boundary scan. any pin designated ?n?only (from functionality point of view) can function as an output during boundary scan. 2.2 i/o circuit summary pnx1500 has a total of 275 functional pins, 1 reserved pin, and 180 power pins. the i/os are powered by a 2.5 v and 3.3 v power supplies. pnx1500 supports 5 v input tolerant pins for certain interfaces such as pci and i 2 c. refer to section 2.3.2 on page 1- 19 for a summary list of the voltage reference for each pin. chapter 1: integrated circuit data pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-2 pnx1500 uses different i/os depending on the type of the interface, e.g. pci, or electrical characteristics needed for the functionality, e.g. a clock signal requires sharper edges than a regular signal. the following table summarizes the types of i/ os, a.k.a. pads, used in pnx1500. the above pad types are used in the modes listed in the following table unused pins may remain unconnected, i.e. ?ating if they contain an internal pull-up or pull-down. more speci?ally, pci_frame_n, pci_tdry_n, pci_irdy_n, pci_devsel_n, pci_stop_n, pci_serr_n, pci_perr_n and pci_inta_n require an external pull-up. refer to section 4.3.3 of pci 2.2 speci?ation for more details. table 1: pnx1500 i/o types pad type description pcit5v pci 2.2 compliant i/o using 3.3- or 5- v pci signaling conventions. iic3m4sdat5v iic3m4sclt5v open drain 3.3- or 5- v i 2 c i/os. bpx2t14mcp 3.3-v low impedance output, with fast rise/fall time, combined with 3.3-v input only. used for clock signals requires board level 27-33 ? series terminator resistor to match 50 ? pcb trace. bpts1cp 3.3-v regular impedance output, with fast rise/fall time, combined with 3.3-v input only. bpts1chp 3.3-v regular impedance output, with fast rise/fall time, combined with 3.3-v input only with hysteresis. bpts3chp 3.3-v regular impedance output, with slow rise/fall time, combined with 3.3-v input only with hysteresis. bpt3mcht5v 3.3-v regular impedance output, with slow rise/fall time, combined with 5-v tolerant input with hysteresis. bpt3mchdt5v 3.3-v regular impedance output, with slow rise/fall time, combined with 5-v tolerant input with hysteresis and internal pull-down. note: the pull-down is not strong enough to actually pull down a 5-v ttl input. instead the ttl input pin sees a ?? ipcp 3.3-v input only. ipchp 3.3-v input only with hysteresis. sstlclkio 2.5 v sstl_2 low impedance, e.g. ddr sdram clocks. requires a board level 10 ? series terminator resistor to match a 50 ? pcb trace. sstladdio 2.5-v sstl_2 low impedance for output signals, e.g. ddr sdram address and control signals. requires a board level matched 50 ? pcb trace. sstldatio 2.5-v sstl_2 low impedance for ddr sdram data signals. requires a board level matched 50 ? pcb trace. table 2: pnx1500 i/o modes modes description in input only, except during boundary scan or gpio mode. out output only, except when used as a gpio pin. od open drain output - active pull low, no active drive high, requires external pull-up. i/o input or output. i/od input or open drain output - active pull low, no active drive high, requires external pull-up. i/o/d input or output or open drain output with input - active pull low, no active drive high, requires external pull- up when operated in open drain mode. o output or ?ating.
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-3 any i/o or i/od signal of the xio bus must be pulled-up if they are not used. gpio[11:8] must be pulled-up or down. the following section 2.3 contains a table that speci?s if the pin contains a pull-up, a pull-down or none (column ??. remark: the pull-down in the bpt3mchdt5v pads is not strong enough to actually pull down a 5-v ttl input. instead the ttl input pin sees a ?? speciality pads, e.g. power supply, are described in the following table. 2.3 signal pin list the following table details the interface of pnx1500. for pad and i/o types, refer to the tables presented in section 2.2 . the i/o type indicates the functional mode (i.e. a dedicated gpio pin is always of i/o/d type). the ??column indicates if the signal is pulled down, ?? or pulled up, ??or neither ?? active low signals are suf?ed by ?n? remark: the pull-down in the bpt3mchdt5v pads is not strong enough to actually pull down a 5-v ttl input. instead the ttl input pin sees a ?? table 3: pnx1500 special i/os name description apio1v2 analog for the 1.2-1.3-v logic. apio3v3 analog for the 3.3-v logic. apod generic analog signal. sstlrefgen reference voltage for the ddr sdram interface. vdde3v3 3.3-v i/o power supply for peripherals i/os. 2.5-v i/o power supply for the memory ddr sdram i/os. these i/os are 3.3-v capable for automated test equipment (ate), not for functional mode. vddi 1.2-1.3-v core power supply. vsse common ground for i/os (i.e. the 2.5-v and 3.3-v power supplies). vssis common ground for the core (i.e. the 1.2-1.3-v power supply). table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description system clock xtal_in d11 apio1v2 in - - pnx1500 main input clock. all internal clocks are derived from this 27 mhz input reference clock. the crystal should be placed as close as possible to the package. refer to figure 1 and figure 25 for board level connections. this input is 1.2v only . xtal_out d9 apio1v2 out - - crystal oscillator output. connect external crystal between this pin and xtal_in. refer to figure 1 and figure 25 for board level connections.
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-4 pci_sys_clk e25 bpx2t14mcp out - u this clock is intended for use as the pci clock in simple pnx1500 pci con?urations. it outputs a 33.23 mhz clock. a board level 27-33 ? series resistor is recommended to reduce ringing. miscellaneous system interface por_in_n a11 bpt3mcht5v in - u pnx1500 power on reset input. asserting this input low triggers the hardware reset function of the pnx1500 ( including the jtag state machine ). this pin can typically be connected to an on-board reset upon voltage drop. it is active low. upon asserting this reset input, the pnx1500 asserts sys_rst_out_n to reset the attached peripheral chips. this pin can also be tied to the pci_rst_n signal in pci bus systems. this pin is 5 v tolerant input. reset_in_n c7 bpt3mcht5v in - u pnx1500 reset input. asserting this input low triggers the hardware reset function of the pnx1500 ( this does not reset the jtag state machine ). upon asserting this reset input, pnx1500 asserts sys_rst_out_n to reset attached peripheral chips. this pin can also be tied to the pci_rst_n signal in pci bus systems. with respect to the por_in_n reset pin, this pin can be used has a warm reset. for most applications, both reset pins can be tied together. it is active low. this pin is 5 v tolerant input. sys_rst_out_n d10 bpx2t14mcp out - u active low peripheral reset output. this output is asserted upon any pnx1500 reset (hardware, watchdog timer or software), and de-asserted by pnx1500 system software. it is intended to be used as a reset for external peripherals. reserved ab23 bpt3mchdt5v i/o - d reserved for future expansion. it has to be left unconnected at the board level for normal operation. it was named reserved2. main memory interface (ddr sdram controller) refer to section 10.3 on pa g e 1- 45 for board design guidelines mm_clk mm_clk_n m1 m2 sstlclkio sstlclkio out out - - - - ddr sdram output clock. refer to section 10.3 on page 1- 45 for board level connections. mm_cs1_n mm_cs0_n v4 l3 sstladdio sstladdio out out - - - - chip select for ddr sdram. it is active low. mm_ras_n l1 sstladdio out - - row address strobe. it is active low. mm_cas_n m4 sstladdio out - - column address strobe. it is active low. mm_we_n n3 sstladdio out - - write enable. it is active low mm_cke j2 sstladdio out - - clock enable output to ddr sdrams. avref n2 sstlrefgen in - - voltage reference. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-5 mm_ba1 mm_ba0 p4 r4 sstladdio sstladdio out out - - - - ddr sdram bank address. it supports 4-bank types of sdrams. mm_addr12 mm_addr11 mm_addr10 mm_addr09 mm_addr08 mm_addr07 mm_addr06 mm_addr05 mm_addr04 mm_addr03 mm_addr02 mm_addr01 mm_addr00 k4 k3 t4 l4 n4 p1 r1 t1 u3 u4 t3 p3 r2 sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio sstladdio out out out out out out out out out out out out out - - - - - - - - - - - - - - - - - - - - - - - - - - ddr sdram address bus. it is used for row and column addresses. mm_dqm3 mm_dqm2 mm_dqm1 mm_dqm0 u2 v3 j4 k2 sstladdio sstladdio sstladdio sstladdio out out out out - - - - - - - - byte write enable signals: mm_dqm0 is attached to byte mm_data[7:0] mm_dqm1 is attached to byte mm_data[15:8] mm_dqm2 is attached to byte mm_data[23:16] mm_dqm3 is attached to byte mm_data[31:24] mm_dqs3 mm_dqs2 mm_dqs1 mm_dqs0 v1 y1 g1 j1 sstldatio sstldatio sstldatio sstldatio i/o i/o i/o i/o - - - - - - - - byte strobe signals: mm_dqs0 is attached to byte mm_data[7:0] mm_dqs1 is attached to byte mm_data[15:8] mm_dqs2 is attached to byte mm_data[23:16] mm_dqs3 is attached to byte mm_data[31:24] table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-6 mm_data31 mm_data30 mm_data29 mm_data28 mm_data27 mm_data26 mm_data25 mm_data24 mm_data23 mm_data22 mm_data21 mm_data20 mm_data19 mm_data18 mm_data17 mm_data16 mm_data15 mm_data14 mm_data13 mm_data12 mm_data11 mm_data10 mm_data09 mm_data08 mm_data07 mm_data06 mm_data05 mm_data04 mm_data03 mm_data02 mm_data01 mm_data00 ad2 ad1 ab2 ac1 ab1 aa2 aa1 w2 w4 y3 y4 aa3 ab3 ab4 ac3 ad3 c3 d3 e4 e3 f3 g4 g3 h4 h2 f1 f2 e1 d1 e2 c1 c2 sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio sstldatio i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ddr sdram data i/o bus. 33 mhz, 32-bit pci 2.2 bus interface and xio 8-bit interface (flash, m68k system bus) (note: buffer design allows drive/receive from either 3.3 or 5 v pci bus) pci_clk e23 pcit5v in - - all pci input signals are sampled with respect to the rising edge of this clock. all pci outputs are generated based on this clock. in small pci con?urations, pci_sys_clk can be used to provide this clock. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-7 pci_ad31 pci_ad30 pci_ad29 pci_ad28 pci_ad27 pci_ad26 pci_ad25 pci_ad24 pci_ad23 pci_ad22 pci_ad21 pci_ad20 pci_ad19 pci_ad18 pci_ad17 pci_ad16 pci_ad15 pci_ad14 pci_ad13 pci_ad12 pci_ad11 pci_ad10 pci_ad09 pci_ad08 pci_ad07 pci_ad06 pci_ad05 pci_ad04 pci_ad03 pci_ad02 pci_ad01 pci_ad00 h24 g26 j23 h25 h26 k23 j25 j26 l23 l24 l25 l26 m24 m23 n23 m25 r26 t26 t25 t24 u26 t23 u24 u23 v26 v23 w26 w25 w24 y26 w23 y23 pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o i/o - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - multiplexed address and data i/o bus. pci_c/be3 pci_c/be2 pci_c/be1 pci_c/be0 k24 m26 r23 v25 pcit5v pcit5v pcit5v pcit5v i/o i/o i/o i/o - - - - - - - - multiplexed bus commands and byte enables. pci_par r24 pcit5v i/o - - even parity across ad[31:0] and c/be[3:0] lines. pci_frame_n n26 pcit5v i/o - - sustained tri-state. frame is driven by a master to indicate the beginning and duration of an access. pci_irdy_n n25 pcit5v i/o - - sustained tri-state. initiator ready indicates that the bus master is ready to complete the current data phase. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-8 pci_trdy_n n24 pcit5v i/o - - sustained tri-state. target ready indicates that the bus target is ready to complete the current data phase. pci_stop_n p24 pcit5v i/o - - sustained tri-state. it indicates that the target is requesting that the master stop the current transaction. pci_idsel k26 pcit5v in - - used as chip select during con?uration read/write cycles. pci_devsel_n p26 pcit5v i/o - - sustained tri-state. it indicates whether any device on the bus has been selected. pci_req_n f23 pcit5v i/o - - if the pnx1500 is the arbiter of the pci bus, this pin acts as a request input for an external device, otherwise it is driven by the pnx1500 as a pci bus master to request the use of the pci bus. pci_gnt_n d24 pcit5v i/o - - if the pnx1500 is the arbiter of the pci bus, this pin acts as an output to grant the requester, otherwise it indicates to the pnx1500 that an access to the bus has been granted. pci_req_a_n g23 pcit5v in - - if the pnx1500 is the arbiter of the pci bus, this pin acts as a request input for an external device. this pin can also be used as an input for an external interrupt line for the tm3260. pci_gnt_a_n d25 pcit5v i/o - - if the pnx1500 is the arbiter of the pci bus, this pin acts as an output to grant the requester. if the internal pci arbiter is not used, this pin can be used as an input for an external interrupt line for the tm3260. pci_req_b_n h23 pcit5v in - - if the pnx1500 is the arbiter of the pci bus, this pin acts as a request input for an external device. this pin can be used as an input for an external interrupt line for the tm3260. this pins is also used as a dsack signal when using the m68k system bus on the pci-xio interface. pci_gnt_b_n d26 pcit5v i/o - - if the pnx1500 is the arbiter of the pci bus, this pin acts as an output to grant the requester. if the internal pci arbiter is not used, this pin can be used as an input for an external interrupt line for the tm3260. pci_perr_n p23 pcit5v i/o - - sustained tri-state. parity errors are generated/ received by the pnx1500 through this pin. pci_serr_n r25 pcit5v od - - system error. this signal is asserted when operating as a target when it detects an address parity error. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-9 pci_inta_n d23 pcit5v i/od - - it is speci?ally intended to be used as the int a pin, so that the software requires less board speci? information. it should be con?ured and used as the pci interrupt output for the case when an external pci host exists. interrupts are asserted by the software running on the tm3260. in standalone systems where the pnx1500 is the pci host, this pin should be con?ured as an input allowing external pci devices to request an interrupt service from the tm3260 cpu. additional xio bus signals to the regular pci bus signals to implement flash, ide drive interface and m68k system buses. xio_d15 xio_d14 xio_d13 xio_d12 xio_d11 xio_d10 xio_d09 xio_d08 aa25 aa26 ad25 y24 y25 ac19 ae26 ac22 pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v pcit5v i/o i/o i/o i/o i/o i/o i/o i/o 34 33 32 31 30 29 28 27 - - - - - - - - xio extended 8-bit data signals for the 16-bit nand/nor ?sh support as well as m68k system buses with a 16-bit wide data path. xio_sel4 xio_sel3 xio_sel2 xio_sel1 xio_sel0 ab24 ac23 ad26 ab25 ab26 pcit5v pcit5v pcit5v pcit5v pcit5v out out out out out - - - - - - - - - - xio chip selects. one is required per component for glue-less connections. xio_ack ac20 pcit5v in 26 - flash/eeprom acknowledge. xio_ad aa24 pcit5v out - - nor flash addressing. video/data in pin group this group provides itu656 8-, 10- and 20-bit inputs, and up to 8-, 16- and 32-bit data streaming input. refer to section 7.1 on pa g e 3- 17 for a detailed de?ition of the operating modes of this pin group. vdi_d33 vdi_d32 ac5 ae2 bpts3chp bpts3chp in in 52 51 d d control for the streaming data mode. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-10 vdi_d31 vdi_d30 vdi_d29 vdi_d28 vdi_d27 vdi_d26 vdi_d25 vdi_d24 vdi_d23 vdi_d22 vdi_d21 vdi_d20 vdi_d19 vdi_d18 vdi_d17 vdi_d16 vdi_d15 vdi_d14 vdi_d13 vdi_d12 vdi_d11 vdi_d10 vdi_d09 vdi_d08 vdi_d07 vdi_d06 vdi_d05 vdi_d04 vdi_d03 vdi_d02 vdi_d01 vdi_d00 ac14 af12 ae12 af11 ac13 ad11 af10 ae10 af9 ac12 ad10 ae9 af8 ad9 ac11 ac10 ae7 ac9 af6 ad8 ae8 ac8 ae5 af5 ac7 ad7 ad6 ad5 af4 ae3 af3 ae4 bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp bpts3chp in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in in - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u video or streaming parallel data and control inputs. vdi_clk1 af7 bpx2t14mcp i/o - u a positive edge on this internally or externally generated clock samples video data. when generated internally, the clock can be software adjusted with sub one hertz accuracy to allow generation of a precisely timed sequence of samples locked to an arbitrary reference, such as a broadcast transport stream source. a board level 27-33 ? series resistor is recommended to reduce ringing. vdi_v1 af13 bpts3chp in 58 d data valid clock quali?r associated with vdi_clk1. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-11 vdi_clk2 ac6 bpx2t14mcp i/o - u a positive edge on this internally or externally generated clock samples streaming data. when generated internally, the clock can be software adjusted with sub one hertz accuracy to allow generation of a precisely timed sequence of samples locked to an arbitrary reference, such as a broadcast transport stream source. a board level 27-33 ? series resistor is recommended to reduce ringing. vdi_v2 ae1 bpts3chp in 59 d data valid clock quali?r associated with vdi_clk2. video/data out pin group the video mode provides itu656 8-, 10- and 16-bit outputs, or digital 24-/30-bit hd yuv outputs, or digital 24-/30-bit rgb/vga outputs. the data streaming mode provides 8-, 16-bit or 32-bit data streaming output. refer to section 7.1 on pa g e 3- 17 for a detailed de?ition of the operating modes of this pin group. vdo_d34 b2 bpts1chp out - u fgpo data bit 7 for extended mode. it was named reserved1. vdo_d33 vdo_d32 a19 b18 bpts1chp bpts1chp out out 54 53 d d control for streaming parallel data outputs. fgpo data bits [4:3] for extended mode. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-12 vdo_d31 vdo_d30 vdo_d29 vdo_d28 vdo_d27 vdo_d26 vdo_d25 vdo_d24 vdo_d23 vdo_d22 vdo_d21 vdo_d20 vdo_d19 vdo_d18 vdo_d17 vdo_d16 vdo_d15 vdo_d14 vdo_d13 vdo_d12 vdo_d11 vdo_d10 vdo_d09 vdo_d08 vdo_d07 vdo_d06 vdo_d05 vdo_d04 vdo_d03 vdo_d02 vdo_d01 vdo_d00 c26 e26 d20 f24 f25 f26 g24 g25 d19 c25 b26 d22 d21 c23 a26 a25 b24 a24 d17 c22 b23 c21 a23 c20 b22 b21 a22 d16 c19 b20 a21 a20 bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp bpts1chp out out i/o out out out out out out out out out out out out out out out out out out out out out out out out out out out out out - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u u video and/or streaming parallel data outputs. vdo_d29 can be used as an input when qvcp is used in vsync slave mode. vdo_clk1 d18 bpx2t14mcp i/o - u a positive or negative edge on this internally or externally generated clock causes transitions of the video samples. when generated internally the clock can be software adjusted with sub one hertz accuracy, to allow generation of a precisely timed sequence of samples locked to an arbitrary reference, such as a broadcast transport stream source. a board level 27-33 ? series resistor is recommended to reduce ringing. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-13 vdo_clk2 b19 bpx2t14mcp i/o - u a positive edge on this internally or externally generated clock causes transitions of the streaming data samples. when generated internally, the clock can be software adjusted with sub one hertz accuracy to allow generation of a precisely timed sequence of samples locked to an arbitrary reference, such as a broadcast transport stream source. a board level 27-33 ? series resistor is recommended to reduce ringing. vdo_aux e24 bpts1chp out 55 d vdo_aux can be programmed to output, a cblank signal, a field indicator or a video/ graphics detector. fgpo_rec_sync c17 bpts1chp i/o 60 d synchronization signal for streaming parallel data outputs. the fgpo data bit 5 is intended for the extended mode. fgpo_buf_sync a18 bpts1chp i/o - d synchronization signal for streaming parallel data outputs. the fgpo data bit 6 is intended for the extended mode. octal audio in (audio in always acts as receiver, but can be set as master or slave for a/d timing) ai_osclk af23 bpx2t14mcp out - u over-sampling clock. this output can be programmed to emit any frequency up to 50 mhz with a sub one hertz resolution. it is intended to be used as the 256 f s or 384 f s over sampling clock by the external a/d subsystem. a board level 27-33 ? series resistor is recommended to reduce ringing. ai_sck ad20 bpx2t14mcp i/o - u ai can operate in either master or slave mode. when audio-in is programmed as the serial- interface timing slave (power-up default), ai_sck is an input. ai_sck receives the serial bit clock from the external a/d subsystem. this clock is treated as fully asynchronous to the pnx1500 main clock. when audio in is programmed as the serial- interface timing master, ai_sck is an output. ai_sck drives the serial clock for the external a/ d subsystem. the frequency is a programmable integral divide of the ai_osclk frequency. ai_sck is limited to 25 mhz. the sample rate of valid samples embedded is variable. if used as a output, a board level 27-33 ? series resistor is recommended to reduce ringing. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-14 ai_ws ad21 bpts3chp i/o 16 u ai can operate in either master or slave mode. when audio in is programmed as the serial- interface timing slave (power-up default), ai_ws acts as an input. ai_ws is sampled on the same edge as selected for ai_sd[3:0]. when audio in is programmed as the serial- interface timing master, ai_ws acts as an output. it is asserted on the opposite edge of the ai_sd[3:0] sampling edge. ai_ws is the word-select or frame-synchronization signal from/to the external a/d subsystem. ai_sd3 ai_sd2 ai_sd1 ai_sd0 ad22 ac17 af24 ae23 bpt3mchdt5v bpt3mchdt5v bpt3mchdt5v bpt3mchdt5v in in in in 20 19 18 17 d d d d serial data from external a/d subsystem. data on this pin are sampled on positive or negative edge of ai_sck as determined by the clock_edge bit in the ai_serial register. these pins are 5 v tolerant input. octal audio out (audio out always acts as sender, but can be set as master or slave for d/a timing) ao_osclk ad19 bpx2t14mcp out - u over sampling clock. this output can be programmed to emit any frequency up to 50 mhz, with a sub one hertz resolution. it is intended to be used as the 256 or 384 f s over sampling clock by the external d/a conversion subsystem. a board level 27-33 ? series resistor is recommended to reduce ringing. ao_sck ae18 bpx2t14mcp i/o - u ao can operate in either master or slave mode. when audio out is programmed to act as the serial interface timing slave (power up default), ao_sck acts as input. it receives the serial clock from the external audio d/a subsystem. the clock is treated as fully asynchronous to the pnx1500 main clock. when audio out is programmed to act as serial interface timing master, ao_sck acts as output. it drives the serial clock for the external audio d/a subsystem. the clock frequency is a programmable integral divide of the ao_osclk frequency. ao_sck is limited to 25 mhz. the sample rate of the valid samples is variable. if used as an output, a board level 27-33 ? series resistor is recommended to reduce ringing. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-15 ao_ws ae20 bpts3chp i/o 21 u ao can operate in either master or slave mode. when audio-out is programmed as the serial- interface timing slave (power-up default), ao_ws acts as an input. ao_ws is sampled on the opposite ao_sck edge at which ao_sd[3:0] are asserted. when audio out is programmed as serial- interface timing master, ao_ws acts as an output. ao_ws is asserted on the same ao_sck edge as ao_sd[3:0]. ao_ws is the word-select or frame- synchronization signal from/to the external d/a subsystem. each audio channel receives 1 sample for every ws period. ao_sd3 ao_sd2 ao_sd1 ao_sd0 af21 af20 ae19 af19 bpts3chp bpts3chp bpts3chp bpts3chp out out out out 25 24 23 22 u u u u serial data to external audio d/a subsystem for ?st 2 of 8 channels. the timing of the transitions on these outputs is determined by the clock_edge bit in the ao_serial register, and can be on a positive or negative ao_sck edge. spdif interface spdi a6 bpt3mchdt5v in 56 d input for spdif (sony/philips digital audio interface, a.k.a. dolby digital tm ), a self clocking audio data stream as per iec958 with 1937 extensions. this pin is 5 v tolerant input. spdo af22 bpx2t14mcp out 57 u output for spdif. note that this low-impedance driver requires a 27-33 ? resistor close to the pnx1500 to match the board line impedance. this resistor becomes a part of the voltage divider necessary to drive the iec958 isolation transformer. 10/100 lan interface (mii) lan_clk af18 bpts1cp out - u clock to feed the external phy, usually 50 mhz. lan_tx_clk/ lan_ref_clk af14 bpts3cp in - u mii transmit clock or rmii reference clock. both lan_tx_clk and lan_rx_clk have to be connected to the rmii reference clock in rmii mode. lan_tx_en ad13 bpts3chp out 35 d mii or rmii transmit enable lan_txd3 lan_txd2 lan_txd1 lan_txd0 af15 ad14 ac15 ae14 bpts3chp bpts3chp bpts3chp bpts3chp out out out out 39 38 37 36 d d d d mii transmit data mii transmit data mii or rmii transmit data mii or rmii transmit data lan_tx_er ae13 bpts3chp out 40 d mii transmit error lan_crs/ lan_crs_dv ac24 bpt3mchdt5v in 41 d mii carrier sense or rmii carrier sene and receive data valid. this pin is 5 v tolerant input. lan_col aa23 bpt3mchdt5v in 42 d collision detect. this pin is 5 v tolerant input. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-16 lan_rx_clk/ lan_ref_clk af16 bpts3cp in - u mii receive clock. both lan_tx_clk and lan_rx_clk have to be connected to the rmii reference clock in rmii mode. lan_rxd3 lan_rxd2 lan_rxd1 lan_rxd0 ad17 ad16 af17 ae16 bpts3chp bpts3chp bpts3chp bpts3chp in in in in 46 45 44 43 u u u u mii receive data mii receive data mii or rmii receive data mii or rmii receive data lan_rx_dv ae15 bpts3chp in 47 u mii receive data valid. lan_rx_er ad15 bpts3chp in 48 d mii or rmii receive error. lan_mdio ac26 bpts3chp i/o 49 u mii management data i/o. lan_mdc ac25 bpts3chp out 50 u mii management data clock. i 2 c interface iic_sda c8 iic3m4sdat5v i/od - - i 2 c serial data. this pin is 5 v tolerant input. iic_scl d8 iic3m4sclt5v i/od - - i 2 c clock. this pin is 5 v tolerant input. gpio - multi-function ?xible software i/o and universal serial interface each gpio pin can be individually set/read by software, or connected to a dma engine that makes it function as a serial pattern generator or serial observer, so that the software can implement complex bit serial i/o protocols. typically, it is used for the ir receiver, ir blaster, switches, lights and serial communications protocols. in addition, any pin with an entry in th e gpio column of this pin list can be (individually) set to act as a gpio pin instead of for its primary function. after power-on reset, every gpio is set to the input mode to avoid any potential electrical con?ct on the board. gpio15/wakeup ac21 bpt3mchdt5v i/o/d 15 d used as a gpio pin. this pin can also be used as the wake-up event once the pnx1500 has been sent into deep power down mode. this pin is 5 v tolerant input. gpio14/gclock02 gpio13/gclock01 gpio12/gclock00 ae22 ae21 ac16 bpts1chp bpts1chp bpx2t14mcp i/o/d i/o/d i/o/d 14 13 12 u u u used as gpio pins. these pins can also be used to output internally generated clocks for external components present on the board ( section 2.11.1 on page 5- 20 ). gpio12/gclock00 requires a board level 27-33 ? series resistor to reduce ringing. gpio11/ boot_mode07 gpio10/ boot_mode06 gpio09/ boot_mode05 gpio08/ boot_mode04/ wdog_out ac18 - ad23 - af26 - af25 bpt3mcht5v - bpt3mcht5v - bpt3mcht5v - bpt3mcht5v - i/o/d - i/o/d - i/o/d - i/o/d - 11 - 10 - 9 - 8 - - - - - - - - - - - after the power up and boot sequence, these pins are used as gpio[11:8] pins. these gpio pins must be strapped with resistors to vdd or vss to determine the pnx1500 boot mode upon reset. gpio[11:10] pins can also be used as input external interrupt lines for the tm3260. the software can assert at regular intervals the wdog_out output pin to prevent an external watchdog device to reset the entire system. other gpio pins can be used for that feature. these pins are 5 v tolerant input. gpio7 ae24 bpt3mchdt5v i/o/d 7 d used as a gpio pin. this pin is 5 v tolerant input. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-17 gpio06/clock06 gpio05/clock05 gpio04/clock04 b9 a8 a7 bpts1chp bpx2t14mcp bpts1chp i/o/d i/o/d i/o/d 6 5 4 u u u used as gpio pins. these pins can also be used to output internally generated clocks for the external components present on the board. these gpio pins can also be used as clocks for sampling or pattern generation in the gpio module ( section 2.11.2 on page 5- 20 ). gpio05/ gclock05 requires a board level 27-33 ? series resistor to reduce ringing. gpio03/clock03/ boot_mode03 a4 bpts1chp i/o/d 3 d after the power up and boot sequence, this pin functions as a gpio[3] pin. this pin can also be used as a clock for sampling or pattern generation in the gpio module. this gpio pin may be strapped with a resistor to vdd or vss to determine the pnx1500 boot mode upon reset. gpio02/clock02/ boot_mode02 gpio01/clock01/ boot_mode01 gpio00/clock00/ boot_mode00 a3 - b3 - b4 - bpts1chp - bpts1chp - bpts1chp - i/o/d - i/o/d - i/o/d - 2 - 1 - 0 - u - u - u - after the power up and boot sequence, these pins are con?ured as gpio[2:0] pins. these pins can also be used as clocks for sampling or pattern generation in the gpio module. these gpio pins may be strapped with resistors to vdd or vss to determine the pnx1500 boot mode upon reset. jtag interface (debug access port and 1149.1 boundary scan port) jtag_tdi a1 ipchp in - u jtag test data input. jtag_tdo d6 bpts3chp o - - jtag test data output. this pin can either be an output, or ?at. it is never an input. jtag_tck b1 ipcp in - u jtag test clock input. jtag_tms d5 ipchp in - u jtag test mode select input. power supplies and ground refer to section 10. on pa g e 1- 43 for board level connection and decoupling associated with these pins. vdda a10 apod pwr - - analog, quiescent vdd, 1.2-1.3 v. refer to figure 25 for board level connections. vssa_1.2 c11 apod gnd - - analog, quiescent ground for the 1.2 v analog supply. refer to figure 25 for board level connections. vcca[] - apod pwr - - analog, quiescent vccp, 3.3 v. refer to figure 24 for board level connections. vssa[] - apod gnd - - analog, quiescent ground. refer to figure 24 for board level connections. vccp[] - vdde3v3 pwr - - 3.3 v i/o power supply for peripherals i/os. vccm[] - vdde3v3 pwr - - 2.5 v power supply for the memory i/os (3.3 v capable of ate, not for functional operation). vdd[] - vddi pwr - - 1.2-1.3 v core power supply. vss[] - vssis gnd - - ground for the core. vss[] - vsse gnd - - ground for the memory i/os. vss[] - vsse gnd - - ground for the peripherals i/os. table 4: pnx1500 interface pin name bga ball pad type i/o type gpio # p description
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-18 2.3.1 power pin list remark: the digital ground for the signals and clocks comes from the same digital ground plane. remark: the digital 1.2 v power supply for the signals and clocks comes from the same digital power plane. table 5: power pin list digital ground 3.3-v 2.5-v 1.2-1.3-v analog 3.3-v analog 1.2-1.3-v vss vccp vccm vdd vssa vcca vssa_1.2 vdda t11 t12 t13 t14 t15 t16 r11 r12 r13 r14 r15 r16 p11 p12 p13 p14 p15 p16 e5 e6 c4 b11 b17 b25 ae11 ae17 ae25 ad4 c15 a13 a9 n11 n12 n13 n14 n15 n16 m11 m12 m13 m14 m15 m16 l11 l12 l13 l14 l15 l16 w1 w3 u25 p2 p25 k25 k5 h1 ab18 ab21 ab22 c16 c5 v5 u5 t2 m3 h3 j5 f4 f5 v22 u22 m22 l22 aa5 aa4 af1 f22 e11 e12 e17 e18 e21 e22 ab5 ab6 aa22 ab11 ab12 ab17 c14 b12 b7 b10 ab7 ab8 ab13 ab14 p22 n22 e13 e14 e7 e8 af2 e19 e20 c12 c18 c24 b6 a2 ae6 ad12 ad18 ad24 ab19 ab20 y22 w22 v24 j24 h22 g22 y5 t5 r5 u1 r3 n1 m5 l5 j3 g2 h5 g5 w5 d2 d4 ac4 ac2 y2 v2 l2 k1 e10 e15 e16 e9 ab10 ab15 ab16 ab9 t22 r22 p5 n5 k22 j22 a15 b14 d13 c10 c6 c9 d12 a12 a17 b15 b13 b16 a14 a5 b8 d15 c13 a16 d14 d7 b5 c11 a10
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-19 2.3.2 pin reference voltage 3. parametric characteristics 3.1 absolute maximum ratings permanent damage may occur if absolute maximum ratings are exceeded. prolonged table 6: pin reference voltage 3.3 v input and/or output 5.0 v input tolerant 3.3 v input and/or output 2.5 v only special por_in_n reset_in_n pci_clk pci_c/be03 pci_c/be2 pci_c/be1 pci_c/be0 pci_par pci_frame_n pci_irdy_n pci_trdy_n pci_stop_n pci_idsel pci_devsel_n pci_req_n pci_gnt_n pci_req_a_n pci_gnt_a_n pci_req_b_n pci_gnt_b_n pci_perr_n pci_serr_n pci_inta_n xio_ack xio_d15 xio_d14 xio_d13 xio_d12 xio_d11 xio_d10 xio_d09 xio_d08 xio_sel4 xio_sel3 xio_sel2 xio_sel1 xio_sel0 xio_ad lan_crs lan_col iic_sda iic_scl reserved pci_ad31 pci_ad30 pci_ad29 pci_ad28 pci_ad27 pci_ad26 pci_ad25 pci_ad24 pci_ad23 pci_ad22 pci_ad21 pci_ad20 pci_ad19 pci_ad18 pci_ad17 pci_ad16 pci_ad15 pci_ad14 pci_ad13 pci_ad12 pci_ad11 pci_ad10 pci_ad09 pci_ad08 pci_ad07 pci_ad06 pci_ad05 pci_ad04 pci_ad03 pci_ad02 pci_ad01 pci_ad00 gpio15 gpio11 gpio10 gpio09 gpio08 gpio07 spdi ai_sd3 ai_sd2 ai_sd1 ai_sd0 pci_sys_clk sys_rst_out_n vdo_clk1 vdo_clk2 vdo_d33 vdo_d32 vdo_d31 vdo_d30 vdo_d29 vdo_d28 vdo_d27 vdo_d26 vdo_d25 vdo_d24 vdo_d23 vdo_d22 vdo_d21 vdo_d20 vdo_d19 vdo_d18 vdo_d17 vdo_d16 vdo_d15 vdo_d14 vdo_d13 vdo_d12 vdo_d11 vdo_d10 vdo_d09 vdo_d08 vdo_d07 vdo_d06 vdo_d05 vdo_d04 vdo_d03 vdo_d02 vdo_d01 vdo_d00 vdo_aux fgpo_rec_sync fgpo_buf_sync vdo_d34 ai_osclk ai_sck ai_ws ao_osclk ao_sck ao_ws ao_sd3 ao_sd2 ao_sd1 ao_sd0 spdo lan_clk lan_tx_clk lan_tx_en lan_tdx03 lan_tdx02 lan_tdx01 lan_tdx00 lan_tx_er lan_rx_clk lan_rxd3 lan_rxd2 lan_rxd1 lan_rxd0 lan_mdio lan_mdc lan_rx_dv lan_rx_er gpio14 gpio13 gpio12 gpio06 gpio05 gpio04 gpio03 gpio02 gpio01 gpio00 jtag_tdi jtag_tck jtag_tms jtag_tdo vdi_clk1 vdi_clk2 vdi_d33 vdi_d32 vdi_d31 vdi_d30 vdi_d29 vdi_d28 vdi_d27 vdi_d26 vdi_d25 vdi_d24 vdi_d23 vdi_d22 vdi_d21 vdi_d20 vdi_d19 vdi_d18 vdi_d17 vdi_d16 vdi_d15 vdi_d14 vdi_d13 vdi_d12 vdi_d11 vdi_d10 vdi_d09 vdi_d08 vdi_d07 vdi_d06 vdi_d05 vdi_d04 vdi_d03 vdi_d02 vdi_d01 vdi_d00 vdi_v1 vdi_v2 mm_clk mm_clk_n mm_cke1 mm_cke2 mm_dqs3 mm_dqs2 mm_dqs1 mm_dqs0 mm_addr12 mm_addr11 mm_addr10 mm_addr09 mm_addr08 mm_addr07 mm_addr06 mm_addr05 mm_addr04 mm_addr03 mm_addr02 mm_addr01 mm_addr00 mm_ba1 mm_ba0 mm_cs1_n mm_cs0_n mm_ras_n mm_cas_n mm_we_n mm_dqm3 mm_dqm2 mm_dqm1 mm_dqm0 mm_data31 mm_data30 mm_data29 mm_data28 mm_data27 mm_data26 mm_data25 mm_data24 mm_data23 mm_data22 mm_data21 mm_data20 mm_data19 mm_data18 mm_data17 mm_data16 mm_data15 mm_data14 mm_data13 mm_data12 mm_data11 mm_data10 mm_data09 mm_data08 mm_data07 mm_data06 mm_data05 mm_data04 mm_data03 mm_data02 mm_data01 mm_data00 xtal_in xtal_out
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-20 operation above the operation range described in section 3.2 but below the maximum ratings may signi?antly reduce the reliability of the pnx1500. 3.2 operating range and thermal characteristics functional operation, long-term reliability and ac/dc characteristics are guaranteed for the operating conditions described in the following table. 4. power supplies sequence no special power sequence is required to operate the pnx15xx series. however, in order to guarantee that mm_cke remains low at power up, the pnx1500 is required to have the 1.2v to come-up before the 2.5v. this is a jedec ddr speci?ation requirement. remark: ddr sdram devices power supply sequence must also be met. refer to the ddr sdram vendor specification. table 7: absolute maximum ratings symbol description minimum maximum units note v ccp 3.3 v i/o supply voltage -0.5 4.6 v v ccm 2.5 v ddr i/o supply voltage -0.5 3.6 v v dd 1.2-1.3-v core supply voltage -0.5 1.7 v v iccp input voltage for 5 v tolerant input pins (i.e. pins supplied by v ccp ) -0.5 6.0 v t stg storage temperature range -65 150 ?c t case operating case temperature range 0 120 ?c hbm esd human body model electrostatic handling for all pins - 2000 v [1] mm esd machine model electrostatic handling for all pins - 150 v [2] [1] class 2, jedec standard, june 2000 [2] class a, jedec standard, october 1997 table 8: operating range and thermal characteristics symbol description minimum typical maximum units v ccp global i/o supply voltage 3.13 3.30 3.47 v v ccm ddr i/o supply voltage. up to ddr333 sdrams require 2.5v. at ddr400 most sdrams require 2.6 v 2.37 2.50 ? 2.60 2.73 v v dd core supply voltage 1.14 ? 1.23 1.2 ? 1.3 1.26 ? 1.37 v v ref input reference level voltage for the ddr i/os. v ccm /2 +/- 100 mv 1.08 ? 1.13 1.25 ? 1.3 1.35 ? 1.47 v t case operating case temperature range 0 - 85 ?c jt junction to case thermal resistance - 6.1 - ?c/w
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-21 5. power supply and operating speeds 6. power consumption the power consumption of the pnx15xx series is dependent on the activity of the tm3260, the number of modules operating, the frequencies at which the system is running, the core voltage, as well as the loads at board level on each pin. 6.1 leakage current power consumption leakage current is a new variable of the advanced cmos processes. the resultant power dissipation is at most 220 mw. it includes the 3 different power supplies. the main part of it is coming from the core power supply, i.e. 1.2 v or 1.3 v with 200 mw out of the maximum 220 mw. this leakage current is variable from silicon to silicon. this means that two pnx1502 can have a signi?ant different leakage current, e.g. as low as 50 mw and as high as 220 mw. the resultant thermal effect must be taken into consideration while designing a board with pnx1500/01/02. 6.2 standby power consumption during the standby (sleep) mode, all the clocks of the pnx1500 system are turned off. a small amount of logic stays alive in order to wake-up the system. the standby mode is obtain by speci?ally turning off the different clocks, i.e. it is not just a simple bit to ?p into a register. once all the clocks have been shutdown the power dissipation is at most 300 mw. 6.3 typical power consumption for typical applications three main techniques can be applied to reduce the ?ut of the box?power consumption of the pnx1500 system: table 9: maximum operating speeds based on the vdd power supply for the pnx1501 core supply (v) tm3260 (mhz) mmi (mhz) mmio (mhz) 2dde mbs vld (mhz) qvcp (out, proc) (mhz) vip (mhz) fgpo fgpi (mhz) dvdd (mhz) pci- xio (mhz) lan (mhz) ao ai (mhz) spdo (mhz) gpio (mhz) 1.2 266 200 157 123 81, 96 81 100 78 33 30 25 40 108 table 10: maximum operating speeds based on the vdd power supply for the pnx1502 core supply (v) tm3260 (mhz) mmi (mhz) mmio (mhz) 2dde mbs vld (mhz) qvcp (out, proc) (mhz) vip (mhz) fgpo fgpi (mhz) dvdd (mhz) pci- xio (mhz) lan (mhz) ao ai (mhz) spdo (mhz) gpio (mhz) 1.3 300 200 157 123 81, 96 81 100 78 33 30 25 40 108
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-22 turn off the unused modules. after reset, the modules are clocked with a 27 mhz clock (input crystal clock, xtal_in). turning off the clocks of the unused modules signi?antly reduces the power consumption. run the pnx1500 system with the adjusted clock speeds for each active module. powerdown the tm3260 every time the os (operating system) reaches the idle task. t ab le 11 and t ab le 12 present a typical example (not optimized for power consumption savings). 6.4 expected maximum currents t ab le 13 and t ab le 14 presents estimated maximum currents, i.e. all modules operating at full speed which is not what a real application will do. board design, i.e. decoupling and regulators, should plan for peak current. peak currents are possible for few cycles it is not sustained current consumption. these peaks will be averaged out by the decoupling capacitors, but regulators should also not be under- dimensioned. 7. dc/ac i/o characteristics the characteristics listed in the following tables apply to the worst case operating condition de?ed in section 3.2 on page 1- 20 . all voltages are referenced to vss (0 v digital ground). the following i/o characteristics includes the effect of process variation. table 11: mpeg-2 decoding with 720x480p output on pnx1501 pnx1501 1.2v 2.6v 3.3v total ma 990 104 53 n/a w 1.188 0.270 0.175 1.634 table 12: mpeg-2 decoding with 720x480p output on pnx1502 pnx1502 1.3v 2.6v 3.3v total ma 1002 104 53 n/a w 1.302 0.270 0.175 1.747 table 13: estimated pnx1501 maximum and peak current pnx1501 1.2v 2.6v 3.3v maximum, ma 1400 300 200 peak, ma 2000 500 300 table 14: estimated pnx1502 maximum and peak current pnx1502 1.3v 2.6v 3.3v maximum, ma 1400 300 200 peak, ma 2000 500 300
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-23 7.1 input crystal speci?ation 7.2 sstl_2 type i/o circuit table 15: speci?ation of hc-49u 27.00000 mhz crystal frequency 27.00000 mhz fundamental temperature range 0 ? c to 85 ? c capacitive load (cl) 18pf-20pf frequency accuracy (all included: temperature, aging, frequency at 0 to 85 ? c) +/-30 ppm series resonance resistor 40 ? max. shunt capacitance 7pf max. drive level 1mw max. motion capacitance 20ff maximum. (as low as possible). figure 1: application diagram of the crystal oscillator table 16: sstl_2 ac/dc characteristics symbol parameter condition/notes min typ max unit notes v oh output high voltage 0.9v ccm v v ol output low voltage 0.1v ccm v v ih dc input high voltage this is the overshoot/ undershoot protection speci?ation of the pad v ccm + 0.3 v v il dc input low voltage -0.3 v v ih-dc dc input high voltage logic threshold v ref + 0.18 v v il-dc dc input low voltage logic threshold v ref - 0.18 v v ih-ac ac input high voltage used for timing speci?ation. see figure 3 . v ref + 0.35 v v il-ac ac input low voltage used for timing speci?ation. see figure 3 . v ref - 0.35 v clock 27 mhz xtal_in xtal_out n.c. 27 mhz pnx1500 pnx1500 xtal_out xtal_in vssa_1.2 cx2 cx1 1.2v input
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-24 [16-1] notes: [16-2] 1. measured into 50 ? load terminated to v ccm /2. r sstl series output resistance high/low level output state 30 40 50 ? 1 t slew slew rate, (v ih-ac - v il-ac )/dt refer to figure 2 and figure 3 . 0.3 0.4 0.5 v/ns c in input pin capacitance 5 pf table 16: sstl_2 ac/dc characteristics symbol parameter condition/notes min typ max unit notes figure 2: sstl_2 test load condition figure 3: sstl_2 receiver signal conditions 12 p f output buffer rise/fall test point 2?true length 50 ? pnx1500 v ih-a c v ih-d c v il-dc v il-ac v ref
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-25 7.3 bpx2t14mcp type i/o circuit bpx2t14mcp i/os require a board level 27-33 ? series resistor to reduce ringing. table 17: bpx2t14mcp characteristics symbol parameter condition/notes min typ max unit v oh output high voltage 0.9v ccp v v ol output low voltage 0.1v ccp v v iht dc input high voltage logic threshold 2.0 v v ilt dc input low voltage logic threshold 0.8 v v ih dc input high voltage this is the overshoot/ undershoot protection speci?ation of the pad v ccp + 0.3 v v il dc input low voltage -0.3 v z o output ac impedance high/low level output state 22 ? pull pull-up/down resistor if applicable 38 66 165 k ? c in input pin capacitance 6 pf figure 4: bpx2t14mcp test load condition 12 p f output buffer rise/fall test point 2?true length 50 ? 28 ? pnx1500
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-26 7.4 bpts1chp and bpts1cp type i/o circuit table 18: bpts1chp and bpts1cp characteristics symbol parameter condition/notes min typ max unit v oh output high voltage 0.9v ccp v v ol output low voltage 0.1v ccp v v iht dc input high voltage logic threshold 2.0 v v ilt dc input low voltage logic threshold 0.8 v v ih dc input high voltage this is the overshoot/ undershoot protection speci?ation of the pad v ccp + 0.3 v v il dc input low voltage -0.3 v z o output ac impedance high/low level output state 38 ? t rf output rise/fall time test load in figure 5 1.2 1.6 2.0 ns pull pull-up/down resistor if applicable 38 66 165 k ? c in input pin capacitance 6 pf figure 5: bpts1chp and bpts1cp test load condition 15 p f output buffer rise/fall test point 2?true length 50 ? pnx1500
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-27 7.5 bpts3chp type i/o circuit table 19: bpts3chp characteristics symbol parameter condition/notes min typ max unit v oh output high voltage 0.9v ccp v v ol output low voltage 0.1v ccp v v iht dc input high voltage logic threshold 2.0 v v ilt dc input low voltage logic threshold 0.8 v v ih dc input high voltage this is the overshoot/ undershoot protection speci?ation of the pad v ccp + 0.3 v v il dc input low voltage -0.3 v z o output ac impedance high/low level output state 45 ? t rf output rise/fall time test load in figure 6 3.0 4.0 5.0 ns pull pull-up/down resistor if applicable 38 66 165 k ? c in input pin capacitance 6 pf figure 6: bpts3chp test load condition 20 p f output buffer rise/fall test point 2?true length 50 ? pnx1500
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-28 7.6 ipchp and ipcp type i/o circuit 7.7 bpt3mchdt5v and bpt3mcht5v type i/o circuit table 20: ipchp and ipcp characteristics symbol parameter condition/notes min typ max unit v iht dc input high voltage logic threshold 2.0 v v ilt dc input low voltage logic threshold 0.8 v v ih dc input high voltage this is the overshoot/ undershoot protection speci?ation of the pad 5.3 v v il dc input low voltage -0.3 v pull pull-up/down resistor if applicable 38 66 165 k ? c in input pin capacitance 5 pf table 21: bpt3mchdt5v and bpt3mcht5v characteristics symbol parameter condition/notes min typ max unit v oh output high voltage 0.9v ccp v v ol output low voltage 0.1v ccp v v iht dc input high voltage logic threshold 2.0 v v ilt dc input low voltage logic threshold 0.8 v v ih dc input high voltage this is the overshoot/ undershoot protection speci?ation of the pad 5.5 v v il dc input low voltage -0.3 v z o output ac impedance high/low level output state 60 ? t rf output rise/fall time test load in figure 7 3.0 4.0 5.0 ns pull pull-up/down resistor if applicable 38 66 165 k ? c in input pin capacitance 6 pf figure 7: bpt3mchdt5v and bpt3mcht5v test load condition 20 p f output buffer rise/fall test point 2?true length 50 ? pnx1500
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-29 7.8 iic3m4sdat5v and iic3m4sclt5v type i/o circuit 7.9 pcit5v type i/o circuit 8. timing speci?ation the characteristics listed in the following tables apply to the worst case operating condition de?ed in section 3.2 on page 1- 20 . the following i/o characteristics includes the effect of process variation. table 22: iic3m4sdat5v and iic3m4sclt5v characteristics symbol parameter condition/notes min typ max unit v ih input high voltage 2.3 5.5 v v il input low voltage -0.5 1.0 v v hys input schmitt trigger hysteresis 0.25 v v ol output low voltage 0.6 v t f output fall time 10 - 400 pf 1.5 250 ns c in input pin capacitance 6 pf table 23: pcit5v characteristics symbol parameter condition/notes min typ max unit v ih-5v input high voltage 2.0 5.75 v v il-5v input low voltage -0.5 0.8 v v ih-3v input high voltage 1.5 5.75 v v il input low voltage -0.5 1.08 v v oh output high voltage 2.7 v v ol output low voltage 0.55 v t rf output fall time between 0.2 v ccp and 0.6 v ccp 1.3 ns c in input pin capacitance 6 8 pf figure 8: pci t val (min) and slew rate test load condition 10 pf 1/2 in. max output 1k ? buffer 1k ? vccp pnx1500
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-30 8.1 reset [24-1] notes: [24-2] 1. can be asserted and de-asserted asynchronously with respect to clk. [24-3] 2. if por_in_n and reset_in_n are asserted low then reset_in_n must stay low for at least as long as por_in_n is asserted low. 8.2 ddr dram interface pnx1500 supports ddr200, ddr266, ddr400{a,b,c} ddr devices as de?ed in the jedec standard jesd79c, march 2003. refer to section 10.3 ddr sdram interf ace for more details. figure 9: reset timing por_in_n reset_in_n t hold t lowr t lowp table 24: reset timing symbol parameter min max units notes t lowp reset active time after power and clock stable 100 s1 t hold reset active after por_in_n is pulled high 0 ns 2 t lowr reset active time after power and clock stable 100 s1 table 25: ddr dram interface timing symbol parameter min max units notes f ddr mm_clk and mm_clk_n frequency 83 200 mhz i.e. up to ddr400 t ddr mm_clk and mm_clk_n period 5 12 ns t cs mm_clk and mm_clk_n skew 0.01 ns t pd-cmd propagation delay for command signals 1.4 3.6 ns 1, 2, 3, 5 t s-dq setup time for mm_dq and mm_dqm (when writing to ddr sdram) - 0.12 t ddr 4, 5 t oh-dq output hold time for mm_dq and mm_dqm (when writing to ddr sdram) 0.12 t ddr 4, 5
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-31 [25-1] notes: [25-2] 1. command signals include mm_cke_n[1:0], mm_cs[1:0]_n, mm_ras_n, mm_cas_n, mm_we_n, mm_ba[1:0] and mm_a[13:0] signals. [25-3] 2. times are measured w.r.t. the positive edge of mm_clk and the crossing point of mm_clk and mm_clk_n. [25-4] 3. refer to figure 2 on page 1- 24 for load conditions. [25-5] 4. times are measured w.r.t. the corresponding edge of mm_dqs[3:0], i.e. mm_dqs[0] if the ddr device is organized in x32, or respectively mm_dq[31:24], mm_dq[23:16], mm_dq[15:8] and mm_dq[7:0] (when applicable) if the ddr devices organized in x8 or x16 are used. [25-6] 5. these timings allow a 250 ps maximum board level skew for mm_ck. mm_ck_n, mm_dqs[3:0] and mm_dq[31:0] for a 200 mhz operating frequency (i.e. ddr400). 8.3 pci bus interface [26-1] notes: [26-2] 1. see the timing measurement conditions in figure 10 . [26-3] 2. minimum times are measured at the package pin with the load circuit shown in figure 8 . maximum times are measured with the load circuits shown in figure 11 . [26-4] 3. pci_req_n and pci_gnt_n are point-to-point signals and have different input setup times. all other signals are bused. [26-5] 4. see the timing measurement conditions in figure 10 . [26-6] 5. all output drivers are floated when pci_rst (may be connected to reset_in_n and/or por_in_n) is active. t iskew-dqs maximum input skew supported (when reading from ddr sdram) 0.2 1.8 ns 2, 5 t is-dq input setup time for mm_dq (when reading from ddr sdram) - 0.6 ns 4, 5 t ih-dq input hold time for mm_dq (when reading from ddr sdram) 1.5 ns 4, 5 table 25: ddr dram interface timing symbol parameter min max units notes table 26: pci bus timing symbol parameter min max units notes t clock minimum high and low times 11 ns 1 t val-pci (bus) clk to signal valid delay, bus signals 2 11 ns 1,2,3 t val-pci (ptp) clk to signal valid delay, point-to-point signals 2 12 ns 1,2,3 t on-pci float to active delay 2 ns 1 t off-pci active to ?at delay 28 ns 1,7 t su-pci input setup time to clk - bus signals 7 ns 3,4 t su-pci (ptp) input setup time to clk - point-to-point signals 12 ns 3,4 t h-pci input hold time from clk ns 4 t rst-off-pci reset active to output ?at delay 40 ns 5,6
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-32 [26-7] 6. for the purpose of active/float timing measurements, the hi-z or ?ff?state is defined to be when the total current delivered through the component pin is less than or equal to the leakage current specification. figure 10: pci output and input timing measurement conditions figure 11: pci t val (max) rising and falling edge v_test t_on t_off v_trise v_tfall t_fval t_rval v_tl v_th clk output tri-state delay output output delay inputs v_test v_tl v_th clk input v_th v_tl valid v_test v_test t_h t_su v_max 5 v signaling v th = 2.4 v v tl = 0.4 v v max = 2.0 v 3.3 v signaling v th = 0.6 v ccp v tl = 0.2 v ccp v max = 0.4 v ccp 10 pf 1/2 in. max output 25 ? buffer pnx1500 10 pf 1/2 in. max output 25 ? buffer vccp pnx1500
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-33 8.4 qvcp, lcd and fgpo interfaces [27-1] see timing measurement conditions figure 12 . [27-2] timing applies when the data is output on a positive or a negative edge in double edge clock mode, see t ab le 1 on page 3- 6 . [27-3] if the vdo_clk[1,2] is inverted internally then the timing applies to the negative edge. [27-4] timing applies for vdo_d[29], fgpo_rec_sync and fgpo_buf_sync. vdo_d[29] and fgpo_buf_sync. this inputs are assumed asynchronous. [27-5] in double edge clock mode, the maximum vdo_clk1 frequency is 65 mhz. in single edge clock mode, positive or negative edge, the maximum vdo_clk1 is 81 mhz. [28-1] see timing measurement conditions figure 12 . [28-2] timing applies when the data is output on a positive or a negative edge in double edge clock mode, see t ab le 1 on page 3- 6 . [28-3] 3. if the vdo_clk[1,2] is inverted internally then the timing applies to the negative edge. table 27: qvcp, lcd and fgpo timing with internal clock generation symbol parameter min max units notes f qvcp vdo_clk1 frequency 65-81 mhz 5 f fgpo vdo_clk2 frequency 100 mhz t clk-dv clock to vdo_d[33:0] and vdo_aux 1.5 6 ns 1, 2, 3 t su-clk input setup time 3 ns 1, 2, 3, 4 t h-clk input hold time 2 ns 1, 2, 3, 4 table 28: qvcp, lcd and fgpo timing with external clock generation symbol parameter min max units notes f qvcp vdo_clk1 frequency 81 mhz 5 f fgpo vdo_clk2 frequency 81 mhz 5 t clk-dv clock to vdo_d[33:0] and vdo_aux 3 11 ns 1, 2, 3 t su-clk input setup time 4 ns 1, 2, 3, 4 t h-clk input hold time 4 ns 1, 2, 3, 4 figure 12: qvcp and fgpo i/o timing vdo_clk vdo_d[34:0] valid t clk-dv fgpo_rec_sync fgpo_buf_sync vdo_clk vdo_d[29] valid t h-clk t su-clk fgpo_rec_sync fgpo_buf_sync
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-34 [28-4] timing applies for vdo_d[29], fgpo_rec_sync and fgpo_buf_sync. vdo_d[29] and fgpo_buf_sync. these inputs are assumed asynchronous. [28-5] maximum frequency may get reduced by the wide spread of propagation delay depending on the application needs, i.e. input setup/hold time requirements of the receiving device. 8.5 vip and fgpi interfaces [29-1] notes: [29-2] 1. timing applies whether the clock is external or internal. [29-3] 2. timing applies whether the data is output on a positive or a negative edge. [29-4] 3. see timing measurement conditions figure 13 . 8.6 10/100 lan in mii mode [30-1] notes: [30-2] 1. timing applies whether the clock is external or internal. [30-3] 2. timing applies whether the data is output on a positive or a negative edge. table 29: vip and fgpi timing symbol parameter min max units notes f vip vdi_clk1 frequency 81 mhz f fgpi vdi_clk2 frequency 100 mhz t su-clk input setup time 3 ns 1, 2, 3 t h-clk input hold time 2 ns 1, 2, 3 figure 13: vip and fgpi i/o timing vdi_clk vdi_d[33:0] valid t h-clk t su-clk vdi_v[1:0] table 30: 10/100 lan mii timing symbol parameter min max units notes f lan_clk lan_clk frequency 60 mhz f clk lan_tx_clk and lan_rx_clk frequency 25 mhz t clk-dv clock to lan outputs 6 17 ns 1, 2, 3 t su-clk input setup time 5 ns 1, 2, 3 t h-clk input hold time 3 ns 1, 2, 3
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-35 [30-4] 3. see timing measurement conditions figure 14 . 8.7 10/100 lan in rmii mode [31-1] notes: [31-2] 1. timing applies whether the clock is external or internal. [31-3] 2. timing applies whether the data is output on a positive or a negative edge. figure 14: lan 10/100 i/o timing in mii mode lan_tx_clk lan_txd[3:0] valid t clk-dv lan_rx_clk lan_tx_en lan_tx_er lan_mdio lan_mdc lan_rx_clk lan_rxd[3:0] valid t h-clk t su-clk lan_crs/col lan_rx_dv lan_tx_clk lan_rx_er lan_mdio table 31: 10/100 lan rmii timing symbol parameter min max units notes f lan_clk lan_clk frequency 60 mhz f clk lan_tx_clk and lan_rx_clk frequency 50 mhz t clk-dv clock to lan outputs 5 13 ns 1, 2, 3 t su-clk input setup time 5 ns 1, 2, 3 t h-clk input hold time 2 ns 1, 2, 3
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-36 [31-4] 3. see timing measurement conditions figure 14 . 8.8 audio input interface [32-1] notes: [32-2] 1. timing applies whether the clock is external or internal. [32-3] 2. timing applies whether the data is output on a positive or a negative edge. figure 15: lan 10/100 i/o timing in rmii mode lan_ref_clk lan_txd[1:0] valid t clk-dv lan_tx_en lan_ref_clk lan_rxd[1:0] valid t h-clk t su-clk lan_crs_dv lan_rx_er table 32: audio input timing symbol parameter min max units notes f osclk audio input oversampling frequency 50 mhz f ai_clk audio input frequency 25 mhz t clk-dv clock to ai_ws 4 10 ns 3 t su-clk input setup time 4 ns 1, 2, 3 t h-clk input hold time 0 ns 1, 2, 3
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-37 3. see timing measurement conditions figure 16 . 8.9 audio output interface [33-1] notes: [33-2] 1. timing applies whether the clock is external or internal. [33-3] 2. timing applies whether the data is output on a positive or a negative edge. figure 16: audio input i/o timing ai_sck valid t clk-dv ai_ws ai_sck ai_sd[3:0] valid t h-clk t su-clk ai_ws table 33: audio output timing symbol parameter min max units notes f osclk audio output oversampling frequency 50 mhz f ao_clk audio output frequency 25 mhz t clk-dv clock to ao_ws and ao_sd[3:0] 4 10 ns 3 t su-clk input setup time 4 ns 1, 2, 3 t h-clk input hold time 0 ns 1, 2, 3
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-38 3. see timing measurement conditions figure 17 . 8.10 spdif i/o interface figure 17: audio output i/o timing ao_sck valid t clk-dv ao_sd[3:0] ao_ws ao_sck ao_sd[3:0] valid t h-clk t su-clk ao_ws table 34: spdif i/o timing symbol parameter min max units notes t high data/clock output high time 12.5 ns figure 18 t low data/clock output low time 12.5 ns figure 18 t ihigh data/clock input high time 8.5 s figure 18 t ilow data/clock input low time 8.5 s figure 18 figure 18: spdif i/o timing spdo spdi t low t ilow t high t ihigh
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-39 8.11 i 2 c i/o interface table 35: i 2 c i/o timing symbol parameter min max units notes f scl scl clock frequency 400 khz figure 19 t buf bus free time 1 s figure 19 t su-sta start condition set up time 1 s figure 20 t h-sta start condition hold time 1 s figure 20 t low iic_scl low time 1 s figure 19 t high iic_scl high time 1 s figure 19 t f iic_scl and iic_sda fall time (cb = 10-400 pf, from v ih- iic to v il-iic ) 20+0.1cb 250 ns figure 19 t su-sda data setup time 100 ns figure 20 t h-sda data hold time 0 ns figure 20 t dv-sda iic_scl low to data out valid 0.5 s figure 20 t dv-sto iic_scl high to data out 1 ns figure 20 figure 19: i 2 c i/o timing iic_scl t high t low t r t f iic_scl iic_sda t tbuf
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-40 8.12 gpio interface [36-1] notes: [36-2] 1. the gpio module can operate up to 108 mhz, however the maximum operating frequency may be limited due to the wide variation of t clk-dv[1,2] . for example if a 4 ns valid window is required for data out then the maximum recommended operating frequency is 50 mhz for t clk-dv1 and 65 mhz for t clk-dv2 . [36-3] 2. timing applies whether the data is output on a positive or negative edge. gpio[6:0] can be selected as clocks. data can be any of the gpio[60:0] as defined in section 2.3 on page 1- 3 . figure 20: i 2 c i/o timing iic_scl iic_sda t h-sta t su-sta iic_scl iic_sda valid t h-sda t su-sda iic_scl ii_csda valid t dv-sto t dv-sda table 36: gpio timing symbol parameter min max units notes f clock gpio sampling/pattern generation clock frequency 108 mhz 1 t clk-dv1 gpio[6:0] clock to data valid for gpio[15:0] pins 3.5 15 ns 1 t clk-dv2 gpio[6:0] clock to data valid for gpio[60:16] pins 3 17.5 ns 1 t su-clk input setup time 6.5 ns 2 t h-clk input hold time 1.5 ns 2 t valid valid time required for sampling mode, i.e. f clock /8 75 ns
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-41 3. see timing measurement conditions figure 21 . 8.13 jtag interface figure 21: audio output i/o timing clock valid t clk-dv data clock data valid t h-clk t su-clk t valid table 37: jtag timing symbol parameter min max units notes f bscan boundary scan frequency 15 mhz f jtag jtag frequency 20 mhz t clk-dv falling edge of the jtag_tck to jtag_tdo 0 8 ns figure 22 t su-clk input setup time 8 ns figure 22 t h-clk input hold time 3 ns figure 22 figure 22: jtag i/o timing jtag_tck jtag_tdi valid t h-tck t su-tck jtag_tms jtag_tck jtag_tdo valid t clk-dv
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-42 9. package outline latest information may be found at http://www.semiconductors.philips.com/package/sot795-1.html#footprint figure 23: bga456 plastic ball grid array; 456 balls; body 27 x 27 x 1.75 mm 125 a a 1 e 1 b a 2 a 2 unit d y e references outline version european projection issue date 02-11-18 iec jedec jeita mm 0.6 0.4 2.45 27.2 26.8 d 1 e 1 25 e 2 24.75 23.75 27.2 26.8 24.75 23.75 1.85 1.60 y 1 0.7 0.5 0.15 0.2 0.35 dimensions (mm are the original dimensions) 144e ms-034 - - - sot795-1 ew 0.3 v 0 10 20 mm scale sot795-1 bga456: plastic ball grid array package; 456 balls; body 27 x 27 x 1.75 mm a max. a 1 detail x y y 1 c x e 1 d d 1 e c a c e g j l n r u w aa ac ae b d f h k m p t v y ab ad af 2468101214161820222426 135791113151719212325 b a ball a1 index area e e e 1 b e 2 1/2 e 1/2 e a c c b ? v m ? w m shape optional (4x)
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-43 10. board design guidelines the following sections discuss the fundamentals of board design for the pnx1500 system. the intent is to give general guidelines on the subject, not the complete in depth coverage. a minimum of four layers board is recommended. 10.1 power supplies decoupling power supply regulators require large smoothing capacitors to deliver the current until the regulator can follow the load conditions. these smoothing capacitors are typically large electrolytic capacitors with considerable parasitic inductance, typically in the order of 10 nh. this high inductance does not allow for rapid supply of varying currents required in high speed processors as the pnx1500. the following recommendations assume a load transient of up to 1 a within 2 ns which is considered conservative for the pnx1500. however, this does guarantee adequate decoupling. in ?igh frequency applications, each power plane vccp, vccm and vdd should be decoupled with at least 10 capacitor of 0.1 f. capacitors should be chosen such that the total series inductance is approximately within the order of 0.2 nh (i.e. 2 nh per capacitor). the parasitic series resistance per capacitor should be in the order of 0.1 ? . ceramic capacitors may be used. these surface mount capacitors should be placed as closely as possible to the power pins of the pnx1500. for ?edium frequency? each power plane vccp, vccm and vdd should be decoupled with at least 10 capacitors of 47 f. capacitors should be chosen such that the total series inductance is approximately with the order of 0.5 nh. the parasitic series resistance per capacitor should be in the order of 0.1 ? . aluminum or wet ?ound foil?tantalum capacitors should not be used. instead, dry tantalum capacitors or equivalent total series resistor and inductance capacitors like the new ceramic or polymer tantalum can be used. despite the larger footprint these surface mount ?edium frequency decoupling capacitors should still be placed as closely as physically possible to the pnx1500 power pins. last step before the power regulator itself is the bulk decoupling. the bulk decoupling can be achieved with ?e 100 f or 220 f capacitors. these capacitors usually have an inductance of 10 nh and internal equivalent series resistance (esr) of 0.1 ? . the amount and size are dependant on how fast the regulator operates. the via connection to the power planes should be as wide as the capacitor soldering lead which is different from a via of a regular signal. the routing and via inductance and resistance must be included when computing the total series inductance and resistance. other devices like the memories also require local decoupling capacitors. three 0.1 f capacitors combined with one 22 for47 f are recommended for each memory device. additional global decoupling can also be distributed across the board.
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-44 10.2 analog supplies 10.2.1 the 3.3 v analog supply the entire analog ground/supply is kept free-?ating on the pcb. quiet vcca for the pll subsystem should be supplied from vccp through a 18 ? series resistor. it should be bypassed for ac to vssa, using a dual capacitor bypass (hi and low frequency ac bypass). quiet vssa for the pll subsystem: the bypass should only be connected to the pnx1500 vssa[] pins and not to the global vss (i.e. ground) network. no external coil or other connection to board ground is needed, such connection would create a ground loop. figure 24 illustrates the analog ?tering for the 3.3 v analog supply. one 47 f and one 10 f is suf?ient for the six vcca[] pins. 10.2.2 the 1.2-1.3-v analog supply the entire analog ground/supply is kept free-?ating on the pcb. all the key components (the analog bypass capacitor and crystal capacitors) are on the pcb connected to the free-?ating analog vssa_1.2 net ( figure 25 , figure 26 ). figure 24: digital vccp power supply to analog vcca/vssa power supply filter 18 ? 47 f 0.1 f pnx1500 vcca[5:0] vssa[5:0] v ccp figure 25: digital vdd power supply to analog vdda/vssa_1.2 power supply filter v dd 1.2-1.3-v vdda xtal_in xtal_out vssa_1.2 pnx1500 47 f 0.1 f 27 mhz 100 ?
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-45 10.3 ddr sdram interface designing a proper ddr sdram interface with the pnx1500 system that guarantees correct signal integrity and timing margins (even at 200 mhz, i.e. ddr400) can be achieved by implementing the following board level design rules: 50 ? trace impedance. the width of the pcb trace as well as the dielectric layer must be adjusted to meet the 50 ? impedance traces. the pnx1500 sstl_2 drivers must be ?e tuned to limit undershoot and/or overshoot over traces with 50 ? impedance. this should guarantee high quality signal integrity. ? shape connection when a signal must be connected to two (or more) memory devices. the bar of the ??should have impedance higher than 50 ? in order to compensate for the trace split. 70 ? is recommended but not required if the bar of the ??is less than half of the ?eg?of the ?? recommended trace lengths for operating frequency of up to ddr400 are shown in t ab le 38 . ddr devices that are ddr400{a,b,c} jedec compliant, revision jesd79c, have tdqss de?ed as 0.72*tck (min) and 1.25*tck (max). faster ddr devices have a more stringent requirement of 0.8*tck and 1.2*tck or even 0.85*tck and 1.15*tck. the pnx1500 can support these fast ddr devices as long as t ab le 38 is strictly followed. in case of using ddr400 only ddr devices, mm_ck/mm_ck# may have a minimum value of 4 cm, the remaining signals should still follow as close as possible the t ab le 38 . figure 26: digital vdd power supply to analog vdda/vssa_1.2 power supply filter v dd 1.2-1.3-v vdda xtal_in xtal_out vssa_1.2 pnx1500 47 f 0.1 f 27 mhz 100 ? 1.2 v n.c. table 38: ddr recommended trance length signal maximum (cm) minimum (cm) mm_ck, mm_ck# 5 5 mm_ad[12:0], mm_ba[1:0] mm_ras/cas/we/cke mm_cs[1:0] 72 mm_dqs[3:0] 3 3 mm_data[31:0] mm_dqm[3:0] 31
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-46 the ball assignment implies that the two outside rows of balls are routed on a different board layer than the next two rows of balls. this is recommended to reduce the skew. the dqs lines are the exception since they are located on the outside row for better package signal integrity. a 10-22 ? series resistor is recommended on the two clock lines. they need to be placed as close as possible to the pnx1500 clock output pins. in addition a 100 ? shunting both memory clocks, i.e. mm_clk and mm_clk#, will reduce the swing of the signals and improve signal integrity. no other termination is required at board level to achieve maximum speed if these rules are strictly followed. above ddr333, i.e. mm_clk of 166 mhz, the 183 or 200 mhz operating speeds (i.e. ddr400) are only available for a maximum of 2 loads. 10.3.1 do ddr devices require termination? most ddr devices are meant to drive very long and highly loaded track lines. their drivers are usually very strong and could use a 22 ? series resistors on the data/dqm and dqs lines on the ddr devices end. 10.3.2 what if i really want to use termination for the pnx1500? it is possible to parallel terminate each line to a termination voltage with a 50 ? resistor for the 200 mhz operation (i.e. ddr400). the resistor should be placed as close as possible to the intersection of the leg of ? and the bar of the ? (this applies when the signal has two or more loads). for single loaded tracks and bi-directional signals, the parallel termination resistor should be placed about 50% of the way to the ddr sdram device. for unidirectional signals and single loaded tracks, the termination should be placed after the pin of ddr sdram device. in this case, the vtt supply must be carefully designed with very wide tracks since the current through that power supply is very high due to the termination and its active current consumption over 80+ pins. mm_cke must not be parallel terminated since it requires a 0v level at initialization time. similarly for signal integrity purpose, it is possible to only series terminate the address, the command lines, and the data lines (at the pnx1500 side). there is no need for series termination if the parallel termination was chosen. 10.4 package handling, soldering and thermal properties up to date package information can be found at http://www.philipslogic.com/packaging/handbook
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-47 11. miscellaneous in order to limit clock jitter on the tm3260 and ddr clocks, it is recommended to shutdown the clocks of the unused modules, typically by programming these modules to enter the powerdown mode and switch the others to their functional clocks (i.e. switch the modules clocks to a frequency higher than the default 27 mhz crystal clock when possible). 12. soft errors due to radiation soft errors can be caused by radiation, electromagnetic interference, or electrical noise. this section reports the soft error rate (ser) caused by the radiation component. there are three primary radiation sources namely alpha particles, high-energy cosmic rays, and neutron-induced boron ?sion. alpha particles originate from radioactive impurities in chip and package materials. cosmic rays indirectly generate charges by colliding with nuclei within the chip. the boron ?sion occurs when a low- energy (thermal) neutron hits a 10b nucleus, which then breaks up into an alpha and lithium recoil. the ser generated by these radiation sources is of 9900 failure-in- time (fit) which is equivalent to one failure every 10 years. in the pnx1500, the ser is statistically improved since some of the memory elements (that are affected by the radiation) may contain pixel data rather than control data which further extends the ser. 13. ordering information table 39: ordering information part name 12 nc speed core voltage package version leadfree end of life pnx1500e 12nc 9352 729 05557 240 mhz 1.2-v bga456 sot795 no 30 june 2005 pnx1501e 12nc 9352 747 28557 266 mhz 1.2-v bga456 sot795 no 30 june 2005 pnx1502e 12nc 9352 747 44557 300 mhz 1.3-v bga456 sot795 no 30 june 2005 pnx1500e/g 12nc 9352 777 46557 240 mhz 1.2-v bga456 sot795 yes pnx1501e/g 12nc 9352 777 47557 266 mhz 1.2-v bga456 sot795 yes pnx1502e/g 12nc 9352 777 48557 300 mhz 1.3-v bga456 sot795 yes
philips semiconductors pnx15xx series volume 1 of 1 chapter 1: integrated circuit data 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 1-48
1. introduction the pnx15xx series media processor is a complete audio/video/graphics system on a chip that contains a high-performance 32-bit vliw processor, trimedia ? tm3260, capable of software video and audio signal processing, as well as general purpose control processing. it is capable of running a psos operating system with real-time signal processing tasks in a single programming and task scheduling environment. an abundance of interfaces make the pnx15xx series suitable for networked audio/visual products. the processor is assisted by several image and video processing accelerators that support image scaling and compositing. figure 1 pictures a high level functional block diagram. 1.1 pnx15xx series functional overview the functionality achieved within the pnx15xx series can be divided into three major categories: decode , processing, and display . decode functions take input data streams and convert those streams into memory based structures that the pnx15xx series may further process. decode functions may be simple, as in the case of storing 656 input video into memory, or substantially more complex, as in the case of mpeg-2. chapter 2: overview pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet figure 1: block diagram pnx15xx series sd or hd yuv422 video in fast general purpose 20 video/fgpi router audio in audio out 2d de scaler & de-interlace 10/100 lan dvd-css 2- layer video out hd/vga/656 fast general purpose interface 656 video/ up to 30-bit up to 32-bit rc pci 2.2 i 2 s s/pdif i 2 s s/pdif pnx15xx 16- or 32-bit i/f, up to 200 mhz ddr sdram 10 flash fast general purpose interface lcd rgb/yuv interface vld ide rmii/mii phy 32 video/fgpi router fast genera l video/ i 2 c 32 32 purpose interface memorystick tm up to 300 mhz, 5-issue tm3260 vliw
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-2 processing functions are those that modify an existing data structure and prepare that structure for display functions. display functions take the processed data structures from memory and generate the appropriate output stream. as in the case of the decode functions, display functions can be relatively simple, such as an i 2 s audio output, or very complex, as in the case of multi-surface composited display. all decoded data structures are stored in memory, even when further processing is not required. this mechanism implies that there is no direct path between input and output data streams. the memory serves as the buffer to de-couple input and output data streams. based on the mode of operation, there may be multiple data structures in memory for a given input stream. the pnx15xx series uses the tm3260 cpu and a timestamping mechanism to determine when a speci? memory data structure is to be displayed. the pnx15xx series implements the required decode, processing, and display functions with a combination of ?ed function hardware and tm3260 cpu software modules. the pnx15xx series provides a good balance between those functions that are implemented in ?ed hardware and those that are programmed to run on the tm3260 cpu. the following tables illustrate how the major tasks are implemented under each of the three main functional areas, and how they map to hardware resources or software. table 1: partitioning of functions to resources function resource description video decoding/acquisition digital video acquisition vip includes optional horizontal down scaling or color space conversion, and conversion to a variety of memory pixel formats mpeg-1/2/4 video decoding software dvd authentication & de-scrambling dvd-css authentication & de-scrambling in hardware audio decoding and improvement processing audio decoding ac3, aac, mpeg l1, l2, mp3, others software decoders for almost any audio format available audio processing software improvement processing and mixing graphics 2d graphics rendering and dma 2d de non-motion compensated de- interlacing mbs median, 2-?ld majority select, 3-?ld majority select with or without eddi post pass for edge improvement motion compensated de-interlacing mbs + software software provides the mbs with a motion compensated ?ld, to which the mbs applies the chosen de-interlacing algorithm motion estimation software pixel accurate and quarter pixel accurate versions available temporal up conversion software creates images temporally between two originals using motion vectors luminance histogram measurement mbs luminance histogram collection during a de-interlace or scaling pass
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-3 1.2 pnx15xx series features summary 32-bit, up to 300 mhz 5-issue vliw cpu with 128 32-bit registers and an extensive set of video and audio media instructions. allows v 2 f power management to control frequency and power consumption based on application requirement. high quality hardware image scaler and advanced de-interlacer, augmented with media processing software to do motion compensated de-interlacing. 2d drawing engine capable of 3 operand bitblt (all 256 raster operations), line drawing, and host font expansion. 10-bit yuv video capture supporting horizontal downscaling scaling up to 40.5 mpix/s. image scaling vip, mbs, qvcp vip can perform horizontal down-scaling during acquisition mbs can perform up-and down scaling horizontal and vertical in a single pass, optionally combined with de-interlacing and format conversions qvcp can perform panoramic horizontal scaling during output video format conversions, including color space conversion vip, mbs, qvcp mbs can convert any pixel format to any other format vip can generate multiple video formats, qvcp can read multiple video formats histogram correction, black stretch, luminance sharpening (lti, cds, hdp), color features (green enhancement, skin tone correction, blue stretch, dynamic color transient improvement) qvcp performed during output to display display processing surface composition with alpha blending, chroma (range) keying qvcp video and graphics scaling qvcp hi-quality panoramic horizontal scaler for video, linear interpolator for graphics gamma correction contrast, brightness, saturation control qvcp discretionary processing mpeg-4 video encoding software mpeg-4 simple or advanced simple pro?e decoding software mpeg-2 video encoding software 1/2 d1 and other versions available transrating/transcoding software, vld the vld hardware can be used to parse a mpeg-2 video stream. software composes a new mpeg-2 stream including the video stream with reduced bitrate. video conferencing a large variety of applications is available table 1: partitioning of functions to resources function resource description
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-4 2-layer compositing video output, with integrated scaling and video improvement processing, supporting w-xga tfts, 1280 x 768 60 hz, hd video, up to 1920 x 1080 60 i, or up to 81 mpix/s. data streaming and message passing ports with up to 400 mb/s bandwidth capability. variable length decoder assist engine. integrated dvd descrambler for dvd playback functionality. octal digital audio in plus s/pdif (dolby digital tm ) input. octal channel digital audio output plus s/pdif (dolby digital tm ) output. integrated controller for uni?d ddr sdram memory system of 16 - 256 mb using 32-bit wide data at up to 400 mhz data rate, i.e. up to 1.6 gb/s. con?urable to a 16-bit wide ddr sdram interface. 32-bit, 33 mhz pci 2.2 interface with integrated pci bus arbiter up to 4 masters. glueless nor and nand 8- or 16-bit flash interface. 4 timers/counters, capable of counting internal and external events. 16 dedicated general purpose i/o pins, suitable as software i/o pins, external interrupt pins, universal remote control blaster, clock source/gate for system event timers/counters and emulating high-speed serial protocols. additional multiplexed general purpose i/o pins. on-chip mpeg-1 and mpeg-2 vld to facilitate transrating, transcoding and software sd mpeg decoding. integrated low-speed, dvd drive capable, ide controller (shares pci pins, requires 2 external buffers to isolate, up to atapi/pio-4). all video/audio timing derived from a single low-cost external crystal (no vcxos required). 10/100 rmii and mii ieee 802.3 phy interface.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-5 2. pnx15xx series functional block diagram figure 1 gives a quick overview of the inside of the pnx15xx series system. each component is further explained in this chapter and later more detailed with a dedicated chapter. figure 2: pnx15xx series functional block diagram pci 33 mhz, 32-bit pci 2.2 mmi vip fgpi 656 data data qvcp-lcd output router fgpo ai 8 ch. i 2 s audio* spdi spdif audio* ao 8 ch. i 2 s audio* spdo spdif audio* misc. i/o, i 2 c gen. purpose i/os 16 vld mbs 2-d de up to 200 mhz (i.e 400 mhz data rate), 16- or 32-bit wide ddr sdram, up to 1.6 gb/s jtag 27 mhz xtal 656/hd/vga note: i/os marked with * can also function as general purpose serial i/o pins instead of in primary function mode legend: mmi - main memory interface vip - video input processor fgpi - fast general purpose input ai - audio in spdi - spdif in (dolby digital) qvcp - quality video compositor processor ao -audio out spdo - spdif out vld - mpeg var. length decoder mbs - memory based (image) scaler de - 2d drawing engine gpio - general purpose software i/o dvd-css - dvd descrambler tmdbg - trimedia software debug 10/100 ethernet mac dvd-css tmdbg 656/data input router 10/100 lan ethernet 10/100 timers, counters, semaphores lcd/data boot, reset, clocks mac* 32 32 with ide drive plus 68k 8- or 16- bit peripheral capability and pci arbiter up to 4 masters includes nand/nor 8- or 16- bit flash pnx15xx tm3260 vliw cpu 5-issue slots, up to 300 mhz 64 k i$, 16 k d$ i2c
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-6 3. system resources 3.1 system reset the pnx15xx series includes a system reset module. this reset module provides a synchronous reset to internal pnx15xx series logic and a reset output pin for initialization of external system components. a system reset can be initiated in response to a board level reset input pin, a software con?uration write or as a result of a programmable watchdog timer time-out. this watchdog timer is a fail-safe recovery mechanism which may be enabled by software. when enabled, a periodic interrupt is sent to the tm3260 cpu. if the cpu does not respond to the interrupt within a programmable time-out period, then the system is assumed to be hung and the system reset is asserted. boot also resets board level peripherals by asserting the sys_rst_out_n pin. 3.2 system booting the pnx15xx series boot method is controlled by the boot_mode[7:0] pins resistive straps. the t ab le 2 shows the main boot modes available. more details can be found in chapter 6 boot module . at the time of the reset_in input deassertion, the code on these pins is sampled. the pins operate as gpio pins after boot. the pnx15xx series on-chip tm3260 cpu is capable of direct standard flash execution to allow for booting. note: direct execution from nand flash, a.k.a. disk flash is not supported. direct execution from ?sh, however, has very limited performance. hence, the tm3260 typically copies a flash ?e to high-performance system dram, and executes it in dram. that flash ?e contains the self- decompressing initial system software application. this multi-stage boot process that starts a compressed code module minimizes system memory cost. table 2: pnx15xx series boot options boot_mode description 000 set up system, and start the tm3260 cpu from a 8-bit nor flash or rom attached to pci/ xio 100 set up system, and start the tm3260 cpu from a 16-bit nor flash or rom attached to pci/ xio 001 set up system, and start the tm3260 cpu from a 8-bit nand flash attached to pci/xio 101 set up system, and start the tm3260 cpu from a 16-bit nand flash attached to pci/xio x10 boots in host assisted mode with a default subsystem id of 0x1234 and a default system vendor id of 0x5678. this boot mode can be used for standalone system but should not be used for a pc pci plug-in card since such a board requires a personal system vendor and subsystem id. instead the i 2 c boot eeprom should be used. s11 boots from a i 2 c eeprom attached to the i 2 c bus. eeproms of 2 kb - 64 kb size are supported. the entire system can be initialized in a custom fashion by the boot command structure. the i 2 c eeprom holds write commands and writes data to internal mmio registers and to the main memory. boot_mode[2] de?es the speed of the i 2 c bus, i.e. 100 or 400 khz. other reserved
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-7 the scripted boot, in combination with an appropriately programmed i 2 c eeprom, allows the pnx15xx series to boot in many ways. a stand-alone pnx15xx series system is able to reliably update its own flash boot image, whether the flash is standard or nand flash. in most systems this is done by extra flash storage capacity that is used by the flash update software to guarantee atomicity of a boot image update under power failure. the update either succeeds or the old boot image is retained. in some systems, however, it may be cost attractive to use a medium size boot i 2 c eeprom instead. this boot eeprom would hold the code to recover a corrupted flash from some system resource such as a network or disk drive. in the presence of an external host processor boot is very different. pnx15xx series must execute an i 2 c eeprom boot script that loads a small amount of board level personality data. once this data is obtained, pnx15xx series is ready to follow the standardized pci enumeration and con?uration protocol executed by the host. in external host con?urations a single small i 2 c eeprom is required, and no flash memory is needed. the host is responsible for con?uring a list of pnx15xx series internal registers, loading an application software image into pnx15xx series dram and starting the tm3260. 3.3 clock system pnx15xx series provides a low cost, highly programmable clock system. all the clocks used within pnx15xx series system can be generated internally with a mixed combination of plls, direct digital synthesizers (ddss) or simple clock dividers depending on the clock module requirements. all the clocks are derived from a low cost 27 mhz crystal clock. this input clock is multiplied internally by 64 to generate a 1.728 ghz clock from which each pnx15xx series module receives a derived clock. this internal high speed clock allows minimal jitter on the generated clocks. 3.4 power management the pnx15xx series system, with its programmable clocks, can be set to operate in 3 different power modes. normal mode in which each module runs at the required speed and the cpu runs at its maximum speed. saving mode in which each module runs at required speed and the cpu runs at the speed that the application needs. for example mp3 audio decoding will require less than 30 mhz, while a simple pro?e mpeg-4 video decoding will require less than 100 mhz. sleep mode in which all the clocks of the system are turned off. a small amount of logic stays alive in order to wake up the system. before going into sleep mode, the cpu can decide that some generated clocks, like the pci clock may remain active. in that case the clocks are gated for each module belonging to pnx15xx series. also the pci outgoing clock may be reduced to xtal_in (27 mhz recommended) divided by 16. the system will not respond to incoming pci transactions or generate outgoing pci transactions, but other pci components may remain operational.the system can wake up upon one of these three events:
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-8 an external wake-up event on pin gpio[15]. when entering in sleep mode, the gpio[15] pin state (i.e. value of the pin) is sampled and registered. the cpu is woken up if the pin gpio[15] changes state (from low to high) after the system has gone into sleep mode. the gpio[15] pin is observable by software. an expired internal counter. before entering in sleep mode, this special counter is set up to count xtal_in clock ticks. once the count is satis?d, the cpu is woken up. the counter has 32 bits. an incoming event is detected by the gpio module (could be a remote control ?ower on command). before going into sleep mode, the cpu sets the gpio event queues to monitor a selected group of gpio pins. once the queues are full or have monitored an event, the cpu is woken up (via an interrupt). this is a more sophisticated wake-up event than the wake-up upon transition on gpio[15] pin event, since several events are sampled and therefore keep the gpio alive. after wake-up from sleep mode, the tm3260 cpu can examine the tentative wake-up attempt, and if the wake-up is genuine, bring the system back to full operational mode. in addition, the clocks to individual unused modules can be turned off altogether and the idle() task of the operating system can be used to activate a voluntary powerdown mechanism in the cpu. these modes are not managed by a hardware power mode controller, but by software using the standard provisions of the cpu and the clock system. 3.5 semaphores the semaphore module implements 16 semaphores for mutual-exclusion in a multi- processor environment. each processor in the system (at board level) can request a particular semaphore. all 16 semaphores are accessed through the same bus which guarantees atomic accesses. there is no built-in mapping of semaphores to sharable hardware system resources. such mapping is done by software convention. each semaphore behaves as follows: if (current_content == 0) new_content = write_value; else if (write_value == 0) new_content = 0; only the lower 12 bits of the semaphore are writable. these lower 12 bits are used by software to write a unique id decided by software convention. the upper 20 bits always return 0 when read. 3.6 i 2 c interface the i 2 c interface on the pnx15xx series provides i 2 c master and slave capability. the i 2 c interface supports two operating modes, the standard mode, which runs at 100 khz, and the fast mode, which runs at 400 khz. the i 2 c interface may be used to connect an optional boot eeprom and/or other peripherals like video/audio adc/dacs at board level.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-9 4. system memory 4.1 mmi - main memory interface pnx15xx series has an uni?d memory system for the pnx15xx series cpu and all of its modules. this memory is also visible from any pci master as pci attached memory. the 32-bit ddr sdram interface can operate up to 200 mhz. this is equivalent to a 64-bit sdr sdram interface running at 200 mhz, resulting in theoretical available bandwidth of up to 1.6 gb/s. this interface can support memory footprints from 8 up to 256 mb. the supported memory con?urations are displayed in t ab le 3 . the memory interface also performs the arbitration of the internal memory bus, guaranteeing adequate bandwidth and latency to the tm3260 cpu, dma devices and other internal resources that require memory access. a programmable list-based memory arbitration scheme is used to customize the memory bandwidth usage of various hardware modules for a given application. the cpu in the system is given the ability to intersect long dma transfers, up to a programmable number of times per interval. this allows optimal cpu performance at high ddr dma utilization rate, and guarantees the real-time needs of audio/video dma modules. the memory controller supports most, if not all, ddr sdram devices thanks to programmable memory timing parameters. for example cas latency, t rc ,t ras ,t rp and many others can be programmed after the default boot initialization. 4.2 flash nand and nor type ?sh memory connects to the pnx15xx series by sharing some pci bus pins. the xio bus created by this pin-sharing supports 8- and 16-bit data peripherals, and uses a few side-band control signals. refer to section 10.3.2 on page 2- 24 for more details. table 3: footprints for 32-bit and 16-bit ddr interface total dram size devices for 32-bit i/f devices for 16-bit i/f 8 mb 1 device of 2m x 32 (64 mbits) 1 device of 4m x 16 (64 mbits) 16 mb 2 devices of 4m x 16 (64 mbits) 1 device of 4m x 32 (128 mbits) 1 device of 8m x 16 (128 mbits) 32 mb 2 devices of 8m x 16 (128 mbits) 1 device of 8m x 32 (256 mbits) 1 device of 16m x 16 (256 mbits) 64 mb 2 devices of 16m x 16 (256 mbits) 1 device of 16m x 32 (512 mbits) 1 device of 32m x 16 (512 mbits) 128 mb 2 devices of 32m x 16 (512 mbits) n/a 256 mb 4 devices of 64m x 8 (512 mbits) 1 rank 4 devices of 32m x 16 (512 mbits) 2 ranks n/a
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-10 pnx15xx series provides 5 chip selects, one of which is intended for a flash device. address range, and wait states for a flash device are programmable. the tm3260 can execute or read from direct addressable flash types. execution from flash is low performance, and only recommended for boot usage. after boot, it is recommended that code ?es be transferred from flash to dram where they can be executed more ef?iently. flash cannot be the target of a module dma write, because write operations require a software ?sh programming protocol. execution and direct addressed read operations only apply to addressable flash types, such as traditional flash, and not to the le system like?nand flash type. peak page mode read performance is 66 mb/s for 16-bit devices and 33 mb/s for 8- bit devices such as the con?urable x8/x16 intel ? strataflash ? (28fxxxj3a, 32mbits, 64mbits, 128mbits) and st mlc-nor ?sh (m58lw064a, 64mbits). cross-page random read accesses each take 4 to 5 pci clock cycles depending on the access- time of the device. flash is mostly used during system boot or low bandwidth system operation to provide a small, non-volatile ?e system. 5. tm3260 vliw media processor core the tm3260 cpu is a version of the trimedia 32-bit vliw media processor. this very long instruction word (vliw) processor operates at up to 300 mhz with 5 instructions per clock cycle, and provides an extensive set of multimedia instructions. it implements the trimedia pnx1300 series instruction set, and has a superset of the pnx1300 series functional units as well as a superset of the multimedia instruction set for better ? with mpeg-4 advanced pro?e decoding. it is backwards compatible with pnx1300 series cpu, but has a larger instruction cache (also referred as i$ or icache) for improved performance. in addition, re-compilation of source code results in higher media performance due to the additional functional units. the tm3260 supports 32-bit integer and ieee compatible 32-bit ?ating point data formats. it also provides a single instruction multiple data (simd) style operation set for operating on dual 16-bit or quad 8-bit packed data. at 266 mhz it has a peak ?ating point compute capacity of 1.0 goperations/s, and has 1.3 gmultiply-add/s capability on 16-bit data. its dual access 16 kb 8- way set-associative data cache provides a cpu local data bandwidth of 2.0 gb/s. its 64 kb 8-way set-associative instruction cache provides 224 bits of instructions every clock cycle (7.1 gb/s), for an instruction rate of 8.8 gop/s. at 300 mhz it has a peak ?ating point compute capacity of 1.4 goperations/s, and has 1.5 gmultiply-add/s capability on 16-bit data. its dual access 16 kb 8- way set-associative data cache provides a cpu local data bandwidth of 2.3 gb/s. its 64 kb 8-way set-associative instruction cache provides 224 bits of instructions every clock cycle (8.0 gb/s), for an instruction rate of 9.9 gb/s. the tm3260 has suf?ient compute performance to deal with a variety of future operating modes. by itself, the processor can decode any known compressed video stream and associated audio at full frame rate, such as decoding a dv camcorder
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-11 image stream, mpeg-2 or mpeg-4 decode. the processor is also capable of doing all audio and video compression, decompression and processing necessary for bi- directional video conferencing. the tm3260 is responsible for all media processing and real-time processing functions within the pnx15xx series. it runs a small real-time operating system, psos, which allows it to respond ef?iently and predictably to real-time events. the tm3260 is capable of operating in little or big-endian mode. the mode is chosen shortly after cpu startup by setting the endian bit in the program control status word (pcsw). debug of software running on tm3260 is performed using an interactive source debugger with a pc jtag plug-in board. the pc talks to the tm3260 through the pnx15xx series jtag pins. the tmdbg module provides an improved version of the pnx1300 series jtag debug port. the pnx15xx series is in standalone mode. tm3260 media processor features are presented bellow. table 4: tm3260 characteristics tm3260 vliw cpu features isa pnx1300 series, with 32-bit risc style load/store/compute instruction set and an extensive set of 8-, 16-bit simd multimedia instructions instructions 5 risc or simd instructions every clock cycle data types boolean, 8-, 16- and 32-bit signed and unsigned integer, 32-bit ieee ?ats functional units 5 const, 5 integer alus, 5 multi-bit shifters, 3 dspalus, 2 dspmul, 2 ifmul, 2 falu, 1 fcomp, 1 ftough (divide, sqrt) 3 branch, 2 ld/st caches 64 kb 8-way set associative icache 16 kb 8-way set associative dual-ported dcache cache policies critical word ?st re?l, write-back, write-allocate, automatic heuristic hardware prefetch line size 64 bytes (both icache and dcache) mmu none, virtual = physical, full 4 gb space supported protection base, limit style protection, where cpu can be set to only use part of system dram, and hardware ensures no references take place outside this range multipliers up to 2 32x32-bit integer multiplies per clock up to 2 32-bit ieee ?ating point multiplies per clock up to 4 16x16-bit multiply-adds per clock up to 8 8x8-bit multiplies per clock debug jtag based software debugger, including hardware breakpoints for instruction and data addresses register ?e 128 entry 32-bit register ?e interrupts 64 auto-vectoring interrupts, with 8 programmable priority levels timers four 32-bit timers/counters are provided. a wide selection of sources allows them to be used for performance analysis, real-time interrupt generation and/or system event counting
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-12 6. mpeg decoding the tm3260 processes the audio, video and the stream de-multiplexing via software. the variable length decoding as well as the authentication and the de-scrambling are supported by two coprocessors. 6.1 vld the pnx15xx series vld is an mpeg-1 and mpeg-2 parser that writes to memory a separate data structure for macro block header and coef?ient information. it is capable of sustaining an atsc (high de?ition) bitrate. it off-loads the cpu in applications involving mpeg-2 decoding or transcoding. low to medium bitrate vld decoding, as well as vlc encoding may be done by the tm3260 cpu. mpeg-2 hd decoding by the cpu is not supported due to cpu and system limitations. 6.2 dvd de-scrambler the dvd-css module is provided to allow integrated dvd playback capability. it provides authentication and de-scrambling for dvds. a dvd drive can be attached to the integrated medium-bandwidth ide controller, and provides its data either across the ide interface or across a multi bit serial interface to the gpio pins. the resulting system memory scrambled program stream is de-scrambled by invoking a memory to memory operation on the dvd-css module. the ?leartext?program stream is then de-multiplexed by software on the tm3260. more detailed information available on (legal) request 7. image processing 7.1 pixel format the on-chip hardware image processing modules all use the same ?ative?pixel formats, as shown in t ab le 5 . this ensures that image data produced by one module can be read by another module. a limited number of native pixel formats are supported by all image subsystems, as appropriate. system interface the tm3260 runs asynchronously with respect to system dram, and can operate at a frequency lower than system dram to save power, or higher than system dram to gain performance software development environment the tm3260 is supported by the advanced c/c++ compiler tools available for the pnx1300 series family application software architecture applications use the tssa, trimedia streaming software architecture, allowing modular development of audio, video processing functions table 4: tm3260 characteristics tm3260 vliw cpu features
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-13 the memory based scaler supports conversion from arbitrary pixel formats to any native format during the anti-?cker ?tering operation. this operation is usually required on graphics images anyway, hence no extra passes are introduced. hardware subsystems support all native pixel formats in both little-endian and big-endian system operation. software always sees the same component layout for a native pixel format unit, whether it is running in little-endian or big-endian mode. i.e. for a given native format, r, g, b (or y,u,v) and alpha are always in the same place. software (on the tm3260 cpu) can be written endian-mode independent, even when doing simd style vectorized computations remark: the native formats of pnx15xx series include the most common indexed, packed rgb, packed yuv and planar yuv formats used by microsoft directx and apple quicktime, with 100% bit layout compatibility in little and big-endian modes of operation, respectively. remark: tm3260 software image processing stages and encoders/decoders typically use semi-planar or planar 4:2:0 or 4:2:2 formats as input and output. 1. vip output of rgb is mutually exclusive with horizontal scaling 2. shown are the 2d engine frame buffer formats where drawing, rasterops and alpha-blending of surfaces can be accelerated. additionally, the 2d drawing engine host port supports 1 bpp monochrome font/pattern data, and 4 and 8-bit alpha only data for host-initiated anti-aliased drawing. table 5: native pixel format summary name note vip out mbs in mbs out 2d engine (2) qvcp- lcd in 1 bpp indexed clut entry = 24-bit color + 8-bit alpha x x 2 bpp indexed xx 4 bpp indexed xx 8 bpp indexed xxx rgba 4444 16-bit unit, containing one pixel with alpha (1) x x x x rgba 4534 (1) x x x x rgb 565 16-bit unit, containing one pixel, no alpha (1) x x x x rgba 8888 32-bit unit, containing one pixel with alpha (1) x x x x packed yuva 4:4:4 32-bit unit containing one pixel with alpha x x x x x packed yuv 4:2:2 (uyvy) 16-bit unit, two successive units contain two horizontally adjacent pixels, no alpha xx x x packed yuv 4:2:2 (yuy2, 2vuy) x x x x planar yuv 4:2:2 three arrays, one for each component x x x semi-planar yuv 4:2:2 two arrays, one with all ys, one with u and vs x x x x planar yuv 4:2:0 three arrays, one for each component x x semi-planar yuv 4:2:0 two arrays, one with all ys, one with u and vs x x x
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-14 7.2 video input processor the video input processor (vip) handles incoming digital video and processes it for use by other components of the pnx15xx series. vip provides 10-bit accurate processing. the vip provides the following functions: receives 10-bit yuv4:2:2 digital video data from the video port. the data is dithered down to in-memory 8-bit data format. the yuv4:2:2 data stream typically comes from devices such as the saa 711x, which digitize pal or ntsc analog video. stores video data inside the video acquisition window in system memory in any of the native pixel formats indicated in t ab le 5 , and performs error feedback rounding to convert the10-bit input to the selected format. provides an internal test pattern generator with ntsc, pal, and variable format support. acquires vbi data using a separate acquisition window from the video acquisition window. performs horizontal scaling, cropping and pixel packing on video data from a continuous video data stream or from a single ?ld or frame. anc header decoding or window mode for vbi data extraction. horizontal up scaling up to 2x. interrupt generation for vbi or video written to memory. sd pixel frequency up to 81 mhz input clock (sd using up to 10-bit yuv ccir- 656). hd pixel frequency up to 81 mhz input clock (hd using 20-bit y,uv input mode). color space conversion (mutually exclusive with scaling). raw data capture up to 81 mhz in either 8- or 10-bit, packed mode with double buffering. vip shares its allocated pins with the fgpi module through an input router. section 9. shows the different operating modes of vip and fgpi modules. 7.3 memory based scaler the pnx15xx series contains a memory based scaler that performs operations on images in main memory. the scaler hardware can either be controlled task by task by the tm3260, or it can be given a list of scaling tasks. the performance of the scaler on large images is typically limited either by the 120 mpixel/s internal processing rate or by the allocated main memory bandwidth. the pnx15xx series mbs can perform: de-interlacing using either a median, 2-?ld majority select, or 3-?ld majority select algorithm with an edge detect/correct post-pass (these three provide increasing quality, at the expense of increased bandwidth requirements)
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-15 edge detect/correct on an input frame that has been software de-interlaced (this provides future capabilities in case we develop a better core de-interlacer than 3- ?ld majority select) horizontal & vertical scaling (on the input image, or on the result of edge detect/ correct stage) linear and non-linear aspect ratio conversion anti ?cker ?tering conversions from any input pixel format to any non-indexed pixel format, including conversions between 4:2:0, 4:2:2 and 4:4:4, indexed to true color conversion, color expansion / compression, de-planarization/planarization (to convert between planar and packed pixel formats, programmable color space conversion) luminance histogram collection, during a scaling or de-interlacing pass note that not all combinations of format conversion with scaling are supported the video processing functions are based on 4- & 6-tap polyphase ?ters with up to 64 phases. three 6-tap ?ter units are used for horizontal scaling/?tering while three 4-tap ?ter units are assigned to vertical scaling/?tering. for some video formats (e.g. yuv 4:2:x) the three 4-tap ?ters can be combined to work as two 6-tap ?ters. 7.4 2d drawing and dma engine a 2d rendering and dma engine (?d de? is included to perform high speed 2d graphics operations. solid ?ls, three operand bitblt, lines, and monochrome data expansion are available. supported drawing formats include 8-, 16-, and 32-bit/pixel. monochrome data can be color expanded to any supported pixel format. anti-aliased lines and fonts are supported via a 16 level alpha blend bitblt. a full 256 level alpha bitblt is available to blend source and destination images together. drawing is supported to any naturally aligned memory location and at any naturally aligned image stride, i.e. 16- and 32-bit pixels should be allocated at byte addresses that are a multiple of 2 and 4 respectively. 7.5 quality video composition processor the pnx15xx series quality video composition processor (qvcp) provides a high resolution graphics controller with graphics and video processing. the qvcp in combination with other modules such as the 2d drawing engine and the mbs (memory base scaler) provides a new generation of graphics and video capability far exceeding the pnx1300 series family. qvcp allows composition of 2 layers, and can output in 656/hd/vga or lcd format in up to 10-bit per component and up to 81 mpixel/s. qvcp contains a series of layers and mixers. the qvcp creates a series of display data layers (pixel streams) and mixes them logically from back to front to create the composited output picture. in order to achieve high quality video and graphics, the qvcp performs the following tasks: fetching of the image surfaces from memory
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-16 per component table lookup, allowing de-indexing or gamma equalization video quality enhancement (luminance transient improvement, color dependent sharpening, horizontal dynamic peaking, histogram modi?ation, digital color transient improvement, black stretch, skin tone correction, blue stretch and green enhancement) video and graphics horizontal up scaling color space uni?ation of all the display surfaces contrast and brightness control positioning of the various surfaces merging of the image surfaces (alpha blending and pixel selection based on chroma range keying) screen timing generation adopted to the connected display requirements (sd- tv standards, hd-tv standards, progressive, interlaced formats, lcd panel control) qvcp supports the semi-planar yuv formats for one layer. both layers support only indexed, rgb and packed yuv formats. qvcp does not support planar video formats. see t ab le 5 for more details. the mixer stage combines images from back to front, also allowing mixing in of a ?ed backdrop color. the mixing operation can be controlled by chroma range keying. mixing modes include per-pixel alpha blending, and color inverting. mixing operations can be programmed by a set of raster operations (rop). mixing is performed either entirely in the rgb domain or the yuv domain, depending on the output mode of operation of the qvcp. after mixing, post-processing optionally down samples 4:4:4 to 4:2:2 in the chroma down sampler (cds). then, vbi insertion may be performed (656 mode only), and the output is formatted to one of the forms as described below: 24- or 30-bit full parallel rgb or yuv 16- or 20-bit y and u/v multiplexed data 8- or 10-bit 656 (full d1, 4:2:2 yuv with embedded sync codes) 8- or 10-bit 4:4:4 format in 656-style with rgb or yuv in each of the output modes, optional h-sync, v-sync and blanking or odd/even outputs are available. the qvcp can be slaved to an external timing source that provides a pixel clock and a frame sync, i.e. vsync. the horizontal sync reference is taken from the frame sync. synchronizing to a traditional ?ld-based vertical sync is not supported. the clock direction is programmed in the clock module while the vsync direction, pin vdo_d[29] is programmed in the qvcp module. pnx15xx series contains a tft lcd controller. it has integrated control of the synchronization signals but also all the lcd speci? commands like power management. de-interlacing of video material is provided in the mbs module. dithering is handled by the qvcp-gnsh block. the qvcp has separate synthesizers for pixel-clock generation. software may use these synthesizers to achieve perfect lock to the transmission source of the digital video that is being displayed by the qvcp.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-17 qvcp shares its allocated pins with the fgpo module through an output router. refer to section 9. for the different operating modes of qvcp and fgpo and pin allocation. 7.5.1 external video improvement post processing the pnx15xx series has a ?do_aux output pin that can be set to signal whether a pixel is a graphics or video pixel. this can be used to suppress post-processing on graphics elements for an attached proprietary video improvement post processor. motion vectors computed by tm3260 software can be sent to a video improvement post-processor over the pci interface. the function of vdo_aux is programmed using the qvcp capability to combine alpha or chroma-keying information during blending. for example, chroma keys in a graphics plane could be used to drive vdo_aux. for another example, a threshold value for an alpha value of a graphics plane could be used to indicate whether a pixel is more than 80% video. 8. audio processing and input/output 8.1 audio processing all audio processing in pnx15xx series is performed in software on the tm3260. this includes decoding of audio from compressed formats, sample rate conversion, mixing and special effects processing. there is suf?ient performance, if required, to transcode received audio to multi-channel compressed audio sent over s/pdif to an attached receiver. (should this say ?rom an attached receiver??) 8.2 audio inputs and outputs the pnx15xx series has several audio input/output facilities: pnx15xx series audio in can capture up to 8 stereo audio inputs with up to 32- bit/sample precision at sample rates up to 96 khz. both audio in and audio out support most a/d converter serial protocols, including i 2 s. sample rate is internally or externally generated. the internal generator is programmable with sub one hertz sampling rate accuracy. audio in also includes a raw mode which allows the capture of any quantity of bits out of the programmable frame (up to 512 bits per frame). the word strobe (ai_ws pin) is also captured and stored into memory. pnx15xx series audio out can generate up to 8 channels of audio, and directly drives up to 4 external stereo i 2 s or similar d/a converters. it supports up to 32- bit/sample precision at sample rates up to 96 khz. the sample rate can be internally or externally generated. the internal generator is programmable with sub one hertz sampling rate accuracy. audio out does not include a raw mode as the audio in module does. pnx15xx series supports a spdif (sony philips digital interface) output with iec-1937 capabilities. transmitted data is generated by tm3260 software. this output port can carry either stereo pcm samples from an internal audio mix, or
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-18 one of the originally received compressed audio programs (5.1 channel ac-3, multi-channel mpeg audio, multi-channel aac). sample rate of transmitted audio is set by software, allowing perfect synchronization to any time reference in the system. pnx15xx series supports a spdif input to connect to external sources, such as a dvd player. the incoming data is timestamped and written to uni?d system memory. data interpretation and sample rate recovery is achieved by software on the tm3260. the audio data received can be in a variety of formats, such as stereo pcm data, 5.1 channel ac-3 data per iec-1937 or other. software decoded audio can be used for mixing with other audio for output along one of the audio outputs. the sample rate is determined by the s/pdif source, and cannot be software controlled. 9. general purpose interfaces vip and qvcp share a set of pins with two general purpose interface modules, fgpi and fgpo (respectively). the input and output data routers allocate a different amount of pins between these four modules. the allocation depends on the operating mode of each module. the following sections describe the different modes of the input and output routers. 9.1 video/data input router these inputs can provide combinations of the following functions: capture of video streams into dram, while performing horizontal scaling and conversion to one of the standard pixel formats, simultaneously with data stream capture low-latency reception of messages from another pnx15xx series capture of unstructured, in?ite parallel data streams into dram capture of 1 or 2-dimensional parallel data streams in dram for message passing and data modes, operating speeds of up to 100 mhz, with 8-, 16- or 32-bit parallel data are supported, providing an aggregate input bandwidth of up to 400 mb/s the vdi pins consist of 38 pins, split into 32 data pins, 2 clock pins and 2 valid signals that indicate whether data is valid on the respective clocks.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-19 the operating modes of the video/data input router are set by the vdi_mode mmio register. a subset of the operating modes are presented in t ab le 6 , which combines 656 digital video source with streaming data inputs. a complete behavior of the output router is available in section 7. on page 3- 16 . section 7.2 summarizes the vip features, while section 9.3 presents some of the fgpi capabilities. in addition to controlling the operating mode of the vdi pins, vdi_mode[7] bit controls the activation of a pre-processing module for the 8-bit data that is routed to the fgpi module. when vdi_mode[7] = ??then the input router scans the lower vdi_d[7:0] inputs for sav/eav codes as de?ed in the video ccir 656 standard and uses the ?tart?and ?top?signals that are routed to the fgpi module as a line and ?ld detector. fgpi can then be programmed to store in dram each ?ld or line at a speci? location which eases the software processing of the data. this processing stage allows to use of fgpi as a second video input as long as ?n the ??pixel processing is not required. a subset of the vdi pins can individually be set to operate as gpio pins in case they are not used for their primary video/streaming data function. 9.2 video/data output router the output router can provide certain combinations of the following functions: refresh a tft lcd display up to w-xga (1280*768) at 60 hz with rgb 18/24- bit per pixel. refresh progressive or interlaced standard de?ition video screens using itu 656 with yuv4:2:2 or 4:4:4 data, with each screen receiving pixels resulting from the composition and processing of two display surfaces stored in dram. refresh of a single high-de?ition 1 or vga resolution screen. table 6: video/data input operating modes mode vip function fgpi function vdi_mode[1:0] = 0x0 (default after reset) 8- or 10-bit itu 656 with additional h&v synchronization signals or 8- or 10-bit raw data up to 22-bit data capture. fgpi is usually set in 16- or 32-bit mode storing into main memory respectively 16- or 32-bit words vdi_mode[1:0] = 0x1 20-bit itu 656 as for hd video with additional h&v synchronization signals up to 12-bit data capture. fgpi can be set in 8-, 16-, or 32-bit mode storing into main memory respectively 8-, 16-, or 32-bit words vdi_mode[1:0] = 0x2 8-bit itu 656 or 8-bit raw data up to 24-bit data capture fgpi is usually set in 32-bit mode storing 32-bit words into main memory. vdi_mode[1:0] = 0x3 n/a 32-bit data capture. fgpi is usually set to 32-bit mode. 1. pnx15xx series does not have the bandwidth and processing power to do a full hdtv decode/ process and hd display, but it can refresh a hd screen and present graphics and video windows on such a screen.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-20 broadcast of messages to 1 or more receiving pnx15xx seriess. message or unstructured data transmission is in 8-, 16- or 32-bit parallel format, with data rates up to 100 mhz, providing an aggregate data rate of up to 400 mb/s. the vdo pins consist of 39 pins, split into 32 data pins, 2 clock pins and 4 control signals. the operating modes of the video/data output router are set by the vdo_mode mmio register. a subset of the operating modes is presented in t ab le 7 . a complete behavior description of the output router is available in section 7. on page 3- 16 . section 7.5 provides a description of the video generation capabilities of the qvcp module, while section 9.4 brie? describes the data streaming/generation features of the fgpo module. a subset of the vdo pins can individually be set to operate as gpio pins in case they are not used for their primary video/streaming data function. 9.3 fast general purpose input the fast general purpose input (fgpi) captures data in a variety of modes: raw mode 8 or 16-bit parallel data. the data is continuously captured as soon as enabled, and is written to memory using double buffering to prevent loss of data table 7: video/data output operating modes mode qvcp function fgpo function vdo_mode[2:0] = 0x0 (reset) tft lcd controller with 24- or 18- bit digital rgb output and associated control signals. 3- or 8-bit data streaming. fgpo is usually set in 8-bit mode. vdo_mode[2:0] = 0x1 digital itu 656 yuv 8-/10-bit and hsync, vsync and cblank signals. 19-bit data streaming. fgpo is usually set in 16- or 32-bit mode, but only the 19 lower bits are output per 16- or 32-bit words. vdo_mode[2:0] = 0x2 digital 16-bit yuv and hsync, vsync and cblank signals. 13-bit data streaming. fgpo can be set in 8-, 16- or 32-bit mode, but only the 13 lower bits are output per 8-, 16- or 32-bit words. vdo_mode[2:0] = 0x3 digital 20-bit yuv and hsync, vsync and cblank signals. 9-bit data streaming. fgpo is usually set in 8- or 16-bit mode, but only the 9 lower bits are output per 8- or 16-bit words. vdo_mode[2:0] = 0x4 digital 24-bit yuv or rgb and hsync, vsync and cblank signals. 5-bit data streaming. fgpo is usually set in 8-bit mode, but only the 5 lower bits are output per 8-bit words. vdo_mode[2:0] = 0x5 digital 30-bit yuv or rgb and hsync, vsync and cblank signals. n/a vdo_mode[2:0] = 0x6 digital itu 656 yuv 8-bit 24-bit data streaming. fgpo is actually set in 32-bit mode but only the 24 lower bits are output per 32-bit words. vdo_mode[2:0] = 0x7 n/a 32-bit data streaming.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-21 8-, 16- or 32-bit message passing between pnx15xx seriess. messages of up to 16 mb in length are received and written to memory. upon completion, an interrupt is generated, and the fgpi switches to the next software input buffer. 8-, 16- or 32-bit structured data capture. data is captured in records, using the rec_start signals to designate when records are started. the buf_start signal can, optionally, be used to force a software buffer switch. this mode can be used to capture 2-dimensionally structured data, such as raw video samples. in combination with vdi_mode[7] bit, see section 9.1 , fgpi can be used as a basic video in module by storing in memory at speci? locations the different lines and ?lds of the in-coming video data. note that the yuv data is stored consecutively in memory and not stored in three different planes. 9.4 fast general purpose output the fast general purpose output (fgpo) provides data generation capabilities that match the fgpi: generation of a structured data stream, indicating record and buffer start over two control wires. generated data can be 8-, 16- or 32-bit wide, with data rates up to 100 mhz at respectively 100, 200 and 400 mb/s. message passing (8-, 16- or 32-bit wide) external synchronization available 10. peripheral interface 10.1 gpio - general purpose software i/o and flexible serial interface pnx15xx series has 16 dedicated gpio pins. in addition, 45 other pins that have a high likelihood of not being used in certain applications are designated as optional gpio pins that can either operate in regular mode or in gpio mode. as an example, some of the data pins of the lan module are available as fully functional gpio in case the system based on pnx15xx series is not connected to a lan network module. the complete list is available in the pin list where a dedicated column de?es the gpio pin number, see section 2.3 on page 1- 3 . the gpio module is connected to many pins. hence it is the ideal place to provide useful central system functions. it performs the following major functions, each detailed below: software i/o - set a pin or pin group, enable a pin (group), inspect pin values precise timestamping of internal and external events (up to 12 signals simultaneously) signal event sequence monitoring or signal generation (up to 4 signals simultaneously)
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-22 10.1.1 software i/o each gpio pin is a tri-state pin that can be individually enabled, disabled, written or read. pins are grouped in groups of 16 and signals within a group can be simultaneously enabled and changed or observed. changes can use a mask to allow certain pins to remain unchanged. note that this capability is useful for low/medium speed software implemented protocols, as well as for observing switches, driving leds etc. it is highly recommended to ?st use the powerful gpio pins as protocol emulators, and not just for static switches/leds (for which a solution such as a pcf8574 i 2 c parallel i/o is ?e). 10.1.2 timestamping the gpio module contains 12 timestamp units, each of which can be designated to monitor an external gpio pin or internal system event. for a monitored event, a timestamp unit can be set to trigger on a rising edge, falling edge or either edge. when a trigger occurs, a precise occurrence time (31-bit timestamp value, 75 ns resolution) is put in a register, and an interrupt is generated. this capability is particularly valuable for precise monitoring of key audio/video events and controlling the internal software phase-locked loops that lock to broadcast time references. it can also be used for medium speed signal analysis. 10.1.3 event sequence monitoring and signal generation gpio contains 4 queue units, each capable of monitoring or generating high-speed signals on up to 4 gpio pins. this capability creates a universal protocol emulator, capable of emulating many medium speed (0 - 20 mbit/s) protocols using software on the tm3260 media processor. complex protocols, such as the memorystick tm protocol with 20 mbits/s peak rate and 800 kb/s sustained ?e transfer rate have been successfully implemented on the pnx8525 gpio module. the pnx15xx series gpio is similar to the pnx8525 gpio module. high speed signal analysis uses one of two modes: event queue hardware samples 1, 2 or 4 gpio inputs using one out of a variety of clocks in the system, including clock inputs or clocks generated from other gpio pins. samples are packed in a word and stored in a list in system memory for software analysis. event queue hardware builds an in-system memory list of timestamped gpio pin change events, individual per monitored gpio pin. edge events are timestamped with 75 ns resolution. signal generation uses the same 2 features, but in reverse, i.e. a sampled signal is transmitted, or an in-memory timestamped list of change events is output over a pin. the event sequence monitoring mechanism can be used for many functions, and is particularly useful for interpreting remote control commands, as described in section 10.2 . signal generation is useful for rc blaster applications.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-23 the gpio module has a total of 4 complex signal analysis/signal synthesis resources capable of sampling or timestamped list generation/creation. 10.1.4 gpio pin reset value dedicated gpio pins come in two types: 50% of the pins will have a ?ow?reset value 50% have a ?igh?reset value this allows use of gpio for a variety of functions. 10.2 ir remote control receiver and blaster pnx15xx series uses the gpio pin event sequence timestamping mechanism and software to interpret remote control commands. the event sequence timestamping can resolve events on signal edges with 75 ns accuracy. a sequence of events followed by a period of inactivity causes generation of an interrupt. software then interprets the ?haracter?by looking at the event list consisting of (time, direction) encoded in memory. this allows interpretation of a wide variety of remote control protocols. the philips rc-5, rc-6 and rc-mm remote control protocols are all decoded with this mechanism, provided that the rf demodulation is performed externally. most other consumer electronic vendor remote control protocols can be supported by appropriate software. similarly, the event generation mechanism can be used to implement ir blaster capability. in this case, the modulator is included - the software generated pulses can be superimposed on an internally generated carrier. there are some speed considerations with this mechanism. each character communicated generates at least one interrupt, and possibly more if the number of edge events exceeds the fifo size. hence, this mechanism is suitable only for protocols that use frequencies up to a few 10s of khz, with low character repetition rates, and not for high speed protocols. 10.3 pci-2.2 & xio-16 bus interface unit pnx15xx series contains an expansion bus interface unit ?ci/xio-16?that allows easy connection of a variety of board level memory components and peripherals. the bus interface is a single set of pins that allows simultaneous connection of 32-bit pci master/slave devices as well as separated address/data style 8- and 16-bit micro processor slave peripherals and standard (nor) or disk-type (nand) flash memory. the bus interface unit contains a built-in single-channel dma unit that can move blocks of data to or from an external peripheral (pci bus master or slave) to or from pnx15xx series dram. the dma unit can access pci as well as 8- and 16-bit wide xio devices. the dma unit packs xio device data to/from 32-bit words, so that no cpu involvement is required to pre/post process data.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-24 10.3.1 pci capabilities pnx15xx series complies with revision 2.2 of the pci bus speci?ation, and operates as a 32-bit pci master/target up to 33 mhz. pnx15xx series as pci master allows tm3260 to generate all single cycle pci transaction types, including memory cycles, i/o cycles, con?uration cycles and interrupt acknowledge cycles. as pci target, pnx15xx series responds to memory transactions and con?uration type cycles, but not to i/o cycles. pnx15xx series can act as pci bus arbiter for up to 3 external masters, i.e. total of 4 masters with pnx15xx series, without external logic. pci clock is an input to pnx15xx series, but if desired the general purpose pnx15xx series pci_sys_clk clock output can be used as the pci 33 mhz clock for the entire system. t ab le 8 summarizes the pci features supported by the pnx15xx series. 10.3.2 simple peripheral capabilities (?io-8/16? the 16-bit micro-processor peripheral interface is a master-only interface, and provides non-multiplexed address and data lines. a total of 26 address bits are provided, as well as a bi-directional, 16-bit data bus. five device pro?es are provided, each generating a chip-select for external devices. up to 64 mb of address space is allowed per device pro?e. the interface control signals are compatible with a motorola 68360 bus interface, and support both ?ed wait-state or dynamic completion acknowledgment. a total of 5 pre-decoded chip select pins are available to accommodate typical outside slave con?urations with minimal or no external glue logic. each chip select pin has an associated programmable address range within the xio address space. each chip select pin can also choose to obey external dtack completion signalling, or be set to have a pre-programmed number of wait cycles. table 8: pnx15xx series pci capabilities as pci target it responds to as pci master it initiates io read io write memory read memory read memory write memory write con?uration read con?uration read con?uration write con?uration write memory read multiple memory read multiple memory read line memory read line memory write and invalidate memory write and invalidate interrupt acknowledge
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-25 the peripheral interface derives 24 of the 26 address wires and 8 out of the 16 data wires from the pci ad[31:0] pins. the remaining pins are xio speci? and non pci shared. an ?io?access looks like a valid pci transaction to pci master/targets on the same wires. unused xio pins are available as gpio pins. the table below summarizes extension capabilities of the bus interface unit. table 9: pci/xio-16 bus interface unit capabilities external device device type capabilities external pci master 32-bit, up to 33 mhz pci masters arbitration built-in for up to 3 external pci masters. additional external masters can be supported with external arbitration. external pci bus masters can perform high bandwidth, low latency dma into and out of pnx15xx series dram. large block transfer capable devices can sustain up to 100 mb/s into dram. external pci slave 32-bit, up to 33 mhz pci targets glueless connection supported for multiple devices subject only to capacitive loading constraints. the tm3260 can perform low-latency 8/16/32-bit writes and reads to/from pci targets. access by tm3260 can be enabled or disabled. external 8-bit slave 8- and 16-bit wide, de-muxed address / data devices on ?io bus up to 5 devices supported gluelessly, or unlimited number subject to capacitive loading rules with external address decode logic. the tm3260 can perform 8-. 16- or 32-bit reads and writes to these ?io?devices, which are automatically mapped to 8- or 16 bit wide transfers by the bus interface unit. standard (nor) flash 8- and 16-bit wide pnx15xx series provides 5 chip selects, one of which is available for a flash device. address range, and wait states for a flash device are programmable. the tm3260 can execute or read from flash. execution is low performance, and only recommended for boot usage. the tm3260 can re-program flash using special software. flash cannot be the target of a module dma write - writes require a software ?sh programming protocol. peak page mode read performance is at 66 mb/s for 16-bit devices and 33 mb/s for 8-bit devices such as intel strataflash (28fxxxj3a, 32 mbits, 64 mbits, 128 mbits) and st mlc-nor ?sh (m58lw064a, 64 mbits). cross-page random read accesses each take 4 to 5 pci clock cycles at 33 mhz depending on the access-time of the device. flash is mostly active during system booting, or with low bandwidth during system operation in order to implement a small non-volatile ?e system. nand flash 8- and 16-bit wide direct execution, direct pi bus read or direct pi bus write from this flash type are not supported. explicit programmed i/o through special nand flash pci/xio-8/ 16 control/status registers is used to implement a ?e system on this disk-like flash type. using the nand-flash xio provisions, a peak bandwidth of 13 mb/s, and a sustained bandwidth of 11 mb/s can be obtained from a am30lv0064d 8mx8 ultranand or equivalent flash device. maximum throughput for serial burst accesses is 33 mb/s for 16-bit devices such as a samsung k9f5616u0b (16 mbits x 16). cimax device 8-bit data, 26-bit address the external logic for conditional access consists of a cimax device, with 2 pcmcia slot devices and glue logic (373, 245). this entire subsystem behaves as an 8-bit wide slave with an up to 26-bit address space. this subsystem interfaces gluelessly to the xio bus, except for the possible logic needed to combine the dtack signalling of multiple devices. there is medium bandwidth of communication between cimax and pnx15xx series, which is expected to not be an issue w.r.t. pci performance. 1394 link core 8-bit data and 9-bit address (philips pdi1394lxx) the philips pdi1394lxx family connects gluelessly to xio in 8-bit data mode using 8-bit data and 9-bit address with dedicated read and write strobes, optional wait signal and a separate chip select. for systems which require high asynchronous performance a 1394 link device with direct pci connection can be used.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-26 10.3.3 ide drive interface the pnx15xx series contains an ide controller that uses some of the pci pins and a few sideband signals. two external ttl devices are all that is required to interface to an actual ide cable/drive. the ide controller capabilities are: controls attached disks in pio mode, for a peak data rate of 16.6 mb/s (pio4) supports sustained bandwidth of up to 10 mb/s sends dma blocks of disk data to and from system dram all ide registers are accessible to tm3260 software 10.4 10/100 ethernet mac the pnx15xx series integrates a 10/100 ethernet mac sub-layer of the ieee 802.3 standard enabling an external phy to be attached through a reduced media independent interface (rmii) or a standard media independent interface (mii). it implements dual transmit descriptor buffers, support for both real-time and non-real- time traf? and support for quality of service (qos) using low-priority and a high- priority transmit queues. among other features the 10/100 ethernet mac module includes: wake-on-lan power management support. this allows system wake-up using receive ?ters or a magic packet detection ?ter. receive ?tering with perfect address matching, a hash table imperfect ?ter and 4 pattern match ?ters. memory traf? optimization via buffering and prefetching the mac address is programmable into an mmio register. the mac address could be located in an externally attached eeprom. 11. endian modes pnx15xx series fully supports little- and big-endian software stacks. docsis devices future docsis devices are expected to be pci bus mastering devices. they connect gluelessly. external sram, rom, eeprom 8- and 16-bit wide counts as generic xio slave device. external dram not supported not supported on pci/xio. external motorola style masters not supported pnx15xx series pci/xio does not support external motorola style masters. pnx15xx series assumes that it is always the master over the xio bus. external 8/16-bit xio dma devices not supported not supported. use one of the streaming dv inputs or outputs instead. table 9: pci/xio-16 bus interface unit capabilities external device device type capabilities
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-27 pnx15xx series always starts in a ?ed endian mode which is determined by the boot script. there is a system provision for tm3260 software to reset and restart the tm3260 in the opposite endian mode such that a ?ld software flash upgrade can release a ?ndian mode opposite boot?software upgrade. pnx15xx series on-chip modules and co-processors observe the system global endian mode ?g. the tm3260 endian mode can be set by the tm3260 program module itself, and should always be set identical to system endian mode. when selecting pci peripherals for a dual-endian mode product, care must be taken to ensure that they can operate without ?pu ?up?in either endian mode. typically, powerpc compatible pci devices support both endian-modes in the exact same way as the pnx15xx series. 12. system debug pnx15xx series uses the jtag port for both the purpose of boundary scan, as well as to implement a remote debug capability for software running on the pnx15xx series cpu. by connecting a pc (running the trimedia sde debugger) through jtag to a pnx15xx series, full start-stop/breakpoint/download type interactive debugging is possible.
philips semiconductors pnx15xx series volume 1 of 1 chapter 2: overview 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 2-28
1. introduction this chapter presents information on the pnx15xx series system on-chip (soc) and its mmio registers. further details on each module composing pnx15xx series are available on dedicated chapters though this databook. reading this chapter is recommended before jumping to the individual module documentation. 2. system memory map pnx15xx series is designed to work in two different environments: standalone and host mode ( figure 1 ). in standalone mode pnx15xx series retrieves its program (i.e. the software application that runs on the tm3260 cpu) from an eeprom or a flash memory device. in this mode the pnx15xx series acts as the master. in host mode pnx15xx series program is downloaded into the pnx15xx series main memory before the tm3260 cpu is released from reset. in this mode the pnx15xx series acts as a slave. this mode is typically used for a pci plug-in card or a standalone system where a control processor is the master. in both modes the pci bus is the main bus used to attach other components of the board system. in order to successfully get all these components working together, it is important to understand pnx15xx series system memory map and its bus structure. following the pci memory addressing principles, pnx15xx series system provides several apertures in its 32-bit address space to communicate to the other devices through the pci bus. at system level, there are three different views of these apertures. the view from the tm3260 cpu, the view from the internal bus, called dcs, and the view from the pci module. the dcs view is introduced to present the overall view of the system memory map. chapter 3: system on chip resources pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet figure 1: the two operating modes of pnx15xx series flash/ide pci agent pci agent pnx15xx pci bus arbiter host cpu (e.g., x86) interrupt controller ide pci agent pci agent pnx15xx flash a) pnx15xx series in host mode b) pnx15xx series in standalone mode as the host (i.e. pci bus pci bus pci bridge
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-2 before going into the details of the three different views the following generic rules should be noted: the three views must be consistent. for example, it is not allowed to have a different dram aperture location for the tm3260 cpu and the pci module. the apertures are ?aturally aligned? for example a 32-megabyte aperture has a starting address that is a multiple of 32 megabytes. each aperture can be located anywhere in the 32-bit addressing space. all the modules in the pnx15xx series soc sees the same memory map, i.e. an address represents an unique location for all the modules. these apertures need to be programmed at boot time or by the host before the system can be operational. the internal boot scripts have pre-de?ed values for these apertures (refer to chapter 6 boot module ). 2.1 the pci view the pci module provides three different apertures to the external pci bus masters: the mmio aperture, used to access all the internal pnx15xx series registers. see section 11. on page 3- 31 for offset allocation per module. the dram aperture, used to access to the main memory of pnx15xx series. the xio aperture, used by tm3260 to access low speed slave devices like flash memories or ide disk drives. any supported request on the pci bus that falls outside of these three apertures is discarded by the pci module and therefore does not interfere with the pnx15xx series system. in addition pci transactions to the xio aperture from external pci agents are discarded. figure 2 presents the memory map seen by the pci module and the remaining of the pnx15xx series system. the apertures can be placed in any order with respect to each other. the aperture locations is programmed by the host cpu. the aperture sizes can be programmed at boot time via some gpio/boot_mode[] pins as de?ed in chapter 6 boot module or they can be programmed by the host cpu using pci con?uration cycles. the mmio aperture is starting at the address contained in the base_14 pci con?uration space register. the dram aperture is starting at the address contained in the base_10 pci con?uration space register. the xio aperture is starting at the address contained in the base_18 pci con?uration space register.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-3 remark: partial 32-bit load or stores from a pci master to an mmio register is not supported. therefore byte of 16-bit half-word accesses are not supported. 2.2 the cpu view the tm3260 cpu supports three different apertures: the mmio aperture, used to access all the internal pnx15xx series registers. see section 11. on page 3- 31 for offset allocation per module. remark: to ensure backward compatibility with future devices, writes to any undefined or reserved mmio bit should be ?? and reads should be ignored. this rules applies to all the modules of pnx15xx series. the dram aperture, used to access the main memory of pnx15xx series which contains the instruction and the data for tm3260 and data used by other pci masters. the apert1 aperture, used by tm3260 to access low speed slave devices like flash memories or ide disk drives that are located in the xio aperture or any other pci slave. tm3260 cpu accesses the three apertures using regular load/store operations. some internal logic in the data cache unit surveys the load/store addresses and routes the request to the appropriate internal pnx15xx series registers (this includes the registers belonging to tm3260) if the address falls into the mmio aperture. if the load/store address falls into the dram aperture the load/store request is routed to the data cache and eventually the main memory. finally if the load/store address falls into the apert1 aperture, the request is send to the pci bus (if it maps to an xio device or a pci internal aperture, see the following section 2.3 ). figure 2 presents the memory map seen by the tm3260 and the remaining of the pnx15xx series system. the apertures can be placed in any order with respect to each other. pnx15xx series allows a host cpu to prevent tm3260 to change its own aperture registers. this can be obtained by ?pping tm32_control.tm32_apert_modifiable to ??( section 2.4.1 ). the aperture locations are de?ed as follows: the mmio aperture is starting at the address contained in the base_14 mmio register. the register is located and owned by the pci module. it is equivalent to the base_14 pci con?uration space register. this is different with respect to pnx1300 series or pnx1300 series where an mmio_base mmio register was available. the dram aperture is starting at the address contained in the tm32_dram_lo mmio register and ?ishes at tm32_dram_hi - 1. remark: if the value 0x0000,0000 is stored into tm32_dram_hi, this value is understood as 0x1,0000,0000. the apert1 aperture is starting at the address contained in the tm32_apert1_lo mmio register and ?ishes at tm32_apert1_hi - 1.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-4 remark: if the value 0x0000,0000 is stored into tm32_apert1_hi, this value is understood as 0x1,0000,0000. 2.3 the dcs view or the system view the dcs bus can be seen as the link between the pci side and the cpu side: requests from the pci bus or the tm3260 targeting the mmio aperture converge to the dcs bus through the mmio apertures and then are dispatched to the corresponding mmio registers. requests from the tm3260 to the apert1 aperture are transferred to the dcs bus and then dispatched to the pci module if the address of the request matches one of the three apertures, pci2, pci1 or xio. these apertures are used to map loads and stores from the cpu to any slave connected to the pci bus. the de?ition of the mmio registers containing the address ranges for the two internal pci apertures can be found in chapter 7 pci-xio module . remark: requests from the tm3260 to apert1 may fall in an non accessible address region in the dcs bus, like between the pci1 and pci2 apertures. it is legal to do so. the request is discarded by the dcs bus controller and a random value is returned upon reads. remark: tm3260 compiler uses speculative loads (i.e. the result of the load may not be used by the cpu) to improve performance. these speculative loads often contain addresses coming from the tm3260 internal register file that are not initialized properly since the return value of the load is not to be used (unless the execution of figure 2: pnx15xx series system memory map 0x0000 0000 inaccessible mmio_base/base_14 mmio aperture tm32_apert1_hi tm32_apert1_lo apert1 aperture 0x1 0000 0000 inaccessible 2mb inaccessible inaccessible tm32_dram_hi tm32_dram_lo dram aperture tm32_dram_climit non-cacheable 0x0000 0000 inaccessible base_14 mmio aperture pci_base1_lo base_18 xio aperture 0x1 0000 000 0 inaccessible 2mb inaccessible inaccessible dcs_dram_hi dcs_dram_lo dram aperture inaccessible mmio aperture inaccessible 2mb inaccessible inaccessible dram aperture base_10 base_18 base_14 pci1 aperture pci2 aperture pci_base1_hi pci_base2_lo pci_base2_hi xio aperture pci1 aperture pci2 aperture 0x1 0000 0000 0x0000 0000 tm3260 dcs pci
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-5 the program is in a phase where it is planned to be used). this creates random addresses that can target the apert1 aperture. therefore the load may generate a transaction on the pci bus that may have some side effects. furthermore the performance are deteriorated by a long cpu stall cycle that is dependent on the completion of pci bus transaction (the cpu does not continue unless the read has completed). to avoid these long cpu stall cycles it is recommended to disable the apert1 when not used. this is achieved by setting the right mode into the tm3260 dc_lock_ctl mmio register or by setting tm32_apert1_lo and tm32_apert1_hi to the same value. requests from the pci bus or the tm3260 targeting the dram aperture do not go through the dcs bus. instead the requests are routed directly to the mmi module. the dram aperture de?ed in the dcs bus is exclusively de?ed for the boot module. when the boot module is programmed to boot pnx15xx series from an eeprom, the boot module fetches write commands from the eeprom. each write command is sent to the dcs bus. if the write address falls between the aperture de?ed by dcs_dram_lo and dcs_dram_hi, section 2.4.1 , then the write data is transferred to the mmi module. this gate allows transfer to the main memory, a binary program, (that is stored into the eeprom) for the tm3260. the bus connecting the module to the mmi is referenced as the mtl bus (see section 10. on page 3- 30 figure 3 ). 2.4 the programmable dcs apertures the address range de?ed by the content of dcs_dram_lo or dcs_dram_hi must not overlap the address ranges of the other apertures on the dcs bus. this can happen temporarily when changing either the dcs_dram_lo or the dcs_dram_hi. therefore any change of the dcs_dram_lo or dcs_dram_hi registers must be done by ?st disabling the dcs dram aperture. this is achieved by starting to change dcs_dram_lo or dcs_dram_hi such that dcs_dram_lo is greater than dcs_dram_hi. similar constraints apply respectively to pci_base1_lo and pci_base1_hi, and pci_base2_lo and pci_base2_hi.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-6 2.4.1 dcs dram aperture control mmio registers 2.5 aperture boundaries the mmio aperture is always 2 megabytes. the dram aperture size range is from 1 to 256 megabytes. de?ed at boot time, it may be changed later on by the tm3260 cpu. the xio aperture size range is from 1 to 128 megabytes. table 1: system registers bit symbol acces s value description dcs dram aperture control registers offset 0x06 3200 dcs_dram_lo 31:16 dcs_dram_lo r/w 0x0000 dcs_dram_lo indicates the lowest dcs bus address mapped to dram. its granularity is of 64 kilobytes. the reset value is 0. writes to this register are controlled by the dcs_dram_we bit in the aperture_we mmio register. 15:0 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. offset 0x06 3204 dcs_dram_hi 31:16 dcs_dram_hi r/w 0x0000 dcs_dram_hi indicates the highest dcs bus address mapped to dram. its granularity is of 64 kilobytes. the reset value of 0 disables memory accesses from the dcs bus. writes to this register are controlled by the dcs_dram_we bit in the aperture_we mmio register. 15:0 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. offset 0x06 3208 aperture_we 31:1 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 0 dcs_dram_we r/w 0x0 ?? writing to dcs_dram_lo or dcs_dram_hi is disabled. ?? writing to dcs_dram_lo or dcs_dram_hi is enabled. when writing to either dcs_dram_lo or dcs_dram_hi occurs, this bit is automatically cleared. by default it is not authorized to write to the dcs_dram_lo and dcs_dram_hi registers. the address range de?ed by the content of dcs_dram_lo or dcs_dram_hi must not overlap the address ranges of the other apertures on the dcs bus. this can happen temporarily when changing either the dcs_dram_lo or the dcs_dram_hi. therefore any change of the dcs_dram_lo or dcs_dram_hi registers must be done by ?st disabling the dcs dram aperture. this is achieved by starting to change dcs_dram_lo or dcs_dram_hi such that dcs_dram_lo is greater than dcs_dram_hi.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-7 other than the pci module, only the tm3260 cpu can emit requests to the pci bus, i.e. none of the other pnx15xx series modules can do so. only the tm3260 cpu and external pci master can request mmio reads or writes. the xio aperture can only be accessed by the tm3260 cpu. 3. system principles the system resources module is like any other module composing the pnx15xx series system. like the other modules it has a module id mmio register as well as powerdown mmio register. 3.1 module id the module id mmio register is used to differentiate between the different modules of the system and different revisions of the same module. for all the modules the mmio content is composed of: an unique 16-bit module id. this id is only changed if the functionality of the module changes signi?antly. module ids 0 and 1 are reserved. an 8-bit revision id composed of a 4-bit major_rev id and a 4-bit minor_rev id. major_rev id is changed upon changing functionality of the module, while the minor_rev id is changed in case of bug ?ing or non functional ?es like yield improvements. an 8-bit value to code the range of recognized mmio addresses by the module. this aperture size allows the module to claim one offset region of the mmio aperture. the offset region or local aperture is de?ed by the following formula, (n + 1) * 4 kilobytes, where n is the 8-bit code stored in the module id register. this is a read only register. see section 3.3 for details on the system module id. 3.2 powerdown bit major powerdown saving is achieved by turning off the clock that feeds the module. the safe procedure to turn off the clock of a module is to write a ? to the powerdown bit located in each module of the system before turning off its clock (whenever it is possible). similarly when powering the module back up, the clock should be turned on before the powerdown bit is ?pped back to ?? when the powerdown bit is activated the module will no longer respond to mmio read or writes other than transactions targeting the powerdown bit. most of the pnx15xx series modules need two different clocks to operate. the streaming clock, e.g. the video pixel clock for qvcp, and the mmio or dcs clock. only the streaming clock should be turned off. therefore, locally some modules may do extra clock gating on the dcs clock when the powerdown bit is turned on. for the system module there is no streaming clock to turn off. details on the mmio register layout is available in the next section 3.3 .
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-8 3.3 system module mmio registers 4. system endian mode pnx15xx series supports both big-endian and little-endian modes, allowing it to run either little-endian or big-endian software, as required by a particular application or system. the operating endian mode of the pnx15xx series system is de?ed in one unique location and it is observed by all the modules in the system. section 4.1 presents the layout of the system endian mode mmio register. table 2: system registers bit symbol acces s value description system module registers offset 0x06 3ff4 glb_reg_power_down 31 power_down r/w 0x0000 power down register for the module 0: normal operation of the module. this is the reset value. 1: module is powered down and the module clock can be removed. at power down, module responds to all reads with 0xdeadabba (except for reads of powerdown register). writes are answered with dcs err signal (except for writes to power down register). 30:0 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. offset 0x06 3ffc glb_reg_mod _id 31:16 module_id r 0x0126 unique 16-bit code. module id 0 and -1 are reserved for future use. 0x0126 indicates a the system register module. 15:12 major_rev r 0x8 changed upon functional revision, like new feature added to previous revision 11:8 minor_rev r 0x1 changed upon bug ? or non functional changes like yield improvement. 7:0 aperture r 0x0 encoded as: aperture size = 4k*(bit_value+1). the bit value is reset to 0 meaning a 4k aperture for the global register 1 module according to the formula above.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-9 4.1 system endian mode mmio registers 5. system semaphores pnx15xx series has 16 simple multi-processor (mp) semaphore-assist devices. they are built out of 32-bit registers, accessible through mmio by either the local tm3260 cpu or by any other cpu located on the pci bus through the aperture made available on the pci module. the semaphores operation is as follows: each master in the system constructs a personal nonzero 12-bit id ( section 5.2 ). to obtain a semaphore, a master is required to do the following actions: write the unique id to one of the 16 semaphores using a 32-bit store. this uses a 32-bit write with the id in the 12 lsbs read back the id. this uses a 32-bit load that returns 0x00000nnn. then if (0x00000nnn == id) { ?erform the short critical section action for which the semaphore was requested? ?hen write 0x00000000 back to the selected semaphore to release it for the other tasks } else {?ry again later, or loop back to write? 5.1 semaphore speci?ation each of the 16 semaphores behavior is de?ed by the following pseudo-code: if (cur_content == 0) { new_content = write_value; } else {if (write_value == 0) new_content = 0;} /* else no action! */ layout and offset address of the 16 semaphores is available in section 5.5 . 5.2 construction of a 12-bit id a system based on pnx15xx series can construct a personal, non-zero 12-bit id in a variety of ways: table 3: system registers bit symbol acces s value description system endian mode registers offset 0x06 3014 sys_endianmode 31:1 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 0 big_endian r/w 0 system endian mode. ?? little endian. ?? big endian.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-10 pci con?space personality entry. each pnx15xx series receives a 16-bit personality value from the eeprom during boot. this personality register is located at offset 0x40 in con?uration space. in a mp system, some of the bits of personality can be individualized for each cpu involved, giving it a unique 2-, 3- or 4-bit id, as needed given the maximum number of cpus in the design. in the case of a host-assisted pnx15xx series boot, the pci bios assigns a unique mmio_base and dram_base to every pnx15xx series. in particular, the 11 msbs of each mmio_base are unique, since each mmio aperture is 2 megabytes in size. these bits can be used as a personality id. set bit 11 (msb) to '1' to guarantee a non-zero id value. 5.3 the master semaphore each pnx15xx series in the system adds a block of 16 semaphores to the mix. the intended use is to treat one of these block of 16 semaphores as the master semaphore block in the system. to determine which semaphore block is master each tm3260 can use pci con?uration space accesses to determine which other pnx15xx seriess are present in the board system. then, the pnx15xx series with the lowest personality number, or the lowest mmio_base is chosen as the pnx15xx series containing the master semaphores. 5.4 usage notes to avoid contention between the different tasks trying to access the different critical resources of the system or the application, pnx15xx series offers 16 different semaphore devices. this allows to use them not only for inter-processor semaphores but also for processes running on a single pnx15xx series. however these process synchronizations within the same processor can use regular memory to memory transactions to implement primitive synchronization. as described here, obtaining a semaphore does not guarantee starvation-free access to critical resources. claiming of one of the semaphores is purely stochastic. this works ?e as long as a particular semaphore is not overloaded. despite a large amount of available semaphores, utmost care should be taken in semaphore access frequency and duration of the basic critical sections to keep the load conditions reasonable.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-11 5.5 semaphore mmio registers table 4: semaphore mmio registers bits symbol acces s value description semaphore registers offset 0x06 3800 semaphore0 31:12 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 11:0 semaphore0 r/w 0 read action does not change this ?ld. writing to this ?ld is accepted only when its current content is zero, upon which the semaphore is locked. the data to be written is zero, upon which the semaphore is unlocked. offset 0x06 3804 semaphore1 31:0 semaphore1 r/w 0 same as semaphore0 register. offset 0x06 3808 semaphore2 31:0 semaphore2 r/w 0 same as semaphore0 register. offset 0x06 380c semaphore3 31:0 semaphore3 r/w 0 same as semaphore0 register. offset 0x06 3810 semaphore4 31:0 semaphore4 r/w 0 same as semaphore0 register. offset 0x06 3814 semaphore5 31:0 semaphore5 r/w 0 same as semaphore0 register. offset 0x06 3818 semaphore6 31:0 semaphore6 r/w 0 same as semaphore0 register. offset 0x06 381c semaphore7 31:0 semaphore7 r/w 0 same as semaphore0 register. offset 0x06 3820 semaphore8 31:0 semaphore8 r/w 0 same as semaphore0 register. offset 0x06 3824 semaphore9 31:0 semaphore9 r/w 0 same as semaphore0 register. offset 0x06 3828 semaphore10 31:0 semaphore10 r/w 0 same as semaphore0 register. offset 0x06 382c semaphore11 31:0 semaphore11 r/w 0 same as semaphore0 register. offset 0x06 3830 semaphore12 31:0 semaphore12 r/w 0 same as semaphore0 register. offset 0x06 3834 semaphore13 31:0 semaphore13 r/w 0 same as semaphore0 register. offset 0x06 3838 semaphore14
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-12 6. system related information for tm3260 this section contains information on how the internal tm3260 resources like its interrupt lines or timers have been assigned or used in the pnx15xx series system. more speci? details on how to program or on the exact behavior of these resources is found in [1]. 6.1 interrupts a fundamental aspect of pnx15xx series system is to provide hardware modules (or hardware accelerators) that relieve the tm3260 cpu for other video/audio processing. these modules are mainly internal bus dma masters. thus once programmed by the tm3260 they only require limited cpu processing power. for example the video module only requires the tm3260 to update the pointers to the next frame 60 times per seconds. an interrupt line is used to signal tm3260 of that need. the tm3260 vectored interrupt controller (vic) provides 64 inputs for interrupt request lines. the interrupt controller prioritizes and maps the multiple requests from the several pnx15xx series modules onto successive interrupt requests to the tm3260 execution unit. t ab le 5 shows the assignment of modules to interrupt source numbers, as well as the recommended operating mode (edge or level triggered). note that there are a total of 7 possible external pins to assert interrupt requests. only pci_inta_n is a dedicated pin for external interrupts. the other pins may be used for other functionality. the ?st 5 interrupt sources, i.e. source 0 through 4, are asserted by active low signal conventions, i.e. a zero level or a negative edge asserts a request. the remaining two external interrupt lines, i.e. source 26 and 27, like all the other regular interrupt lines, operate with active high signalling conventions. 31:0 semaphore14 r/w 0 same as semaphore0 register. offset 0x06 383c semaphore15 31:0 semaphore15 r/w 0 same as semaphore0 register. table 4: semaphore mmio registers ?ontinued bits symbol acces s value description table 5: interrupt source assignments source name source number interrupt operating mode source description pci_inta_n 0 level external pci int a interrupt used by the host cpu. active low pci_gnt_a_n 1 level direct external interrupt input line, active low pci_gnt_b_n 2 level direct external interrupt input line, active low pci_req_a_n 3 level direct external interrupt input line, active low pci_req_b_n 4 level direct external interrupt input line, active low timer1 5 edge general purpose internal tm3260 timer. timer2 6 edge general purpose internal tm3260 timer.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-13 timer3 7 edge general purpose internal tm3260 timer. systimer 8 edge general purpose internal tm3260 timer. vip 9 level video input processor qvcp 10 level quality video composition processor ai 11 level audio input ao 12 level audio output spdi 13 level s/pdif input spdo 14 level s/pdif output ethernet 15 level ethernet mac 10/100 i2c 16 level i 2 c interface tmdbg 17 level jtag interface fgpi 18 level fast generic parallel input interface fgpo 19 level fast generic parallel output interface reserved 20...21 n/a reserved for future devices mbs 22 level memory base scaler de 23 level 2d drawing engine vld 24 level variable length decoder dvd-css 25 level dvd descrambler gpio[10] 26 level direct external interrupt input line, active high gpio[11] 27 level direct external interrupt input line, active high hostcom 28 edge (software) host communication application 29 edge (software) application debugger 30 edge (software) debugger rtos 31 edge (software) real time operating system gpio_int0 32 level general purpose i/o interrupt line 0, fifo 0 gpio_int1 33 level general purpose i/o interrupt line 1, fifo 1 gpio_int2 34 level general purpose i/o interrupt line 2, fifo 2 gpio_int3 35 level general purpose i/o interrupt line 3, fifo 3 gpio_int4 36 level general purpose i/o interrupt line 4, tsu units pci 37 level peripheral component interconnect error monitoring pci_gppm 38 level pci single data phase transfer completed pci_gpxio 39 level pci xio transaction completed pci_dma 40 level pci dma transaction completed clock 41 level clock generation watchdog 42 level on-chip watchdog timer reserved 43...59 n/a reserved for future devices table 5: interrupt source assignments source name source number interrupt operating mode source description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-14 6.2 timers the tm3260 cpu contains four programmable timer/counters, all with the same function. the ?st three (timer1, timer2, timer3) are intended for general use. the fourth timer/counter (systimer) is reserved for use by the system software and should not be used by applications. each timer/counter can be set to count one of the event types speci?d in t ab le 6 . note that source 3 to 6 are special tm3260 events used for program debug support as well as cache performance monitoring. full description can be found in [1]. for all the other source signals, like the vdo_clk1 pin, positive-going edges on the signal are counted. each timer increments its value until the programmed count is reached. on the clock cycle when the timer reaches its programmed count value, an interrupt is generated. the timer interrupt source mode should be set as edge-sensitive as presented in t ab le 5 . no software interrupt acknowledge to the timer device is necessary. dcs 60 level internal dcs bus mmi 61 level main memory interface, i.e. the dram controller reserved 62...63 n/a reserved for future devices table 5: interrupt source assignments source name source number interrupt operating mode source description table 6: tm3260 timer source selection source name source number source description tm3260 clock 0 the cpu clock prescale 1 pre-scaled cpu clock reserved 2 reserved for future devices databreak 3 data breakpoints instbreak 4 instruction breakpoints cache1 5 cache event 1 cache2 6 cache event 2 vdi_clk1 7 vip clock pin vdi_clk2 8 fgpi clock pin vdo_clk1 9 qvcp clock pin vdo_clk2 10 fgpo clock pin ai_ws 11 ai word strobe pin ao_ws 12 ao word strobe pin gpio_timer0 13 gpio pin selection 0 gpio_timer1 14 gpio pin selection 1 reference_clock 15 the 27 mhz input crystal clock
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-15 6.3 system parameters for tm3260 few more control parameters are available to tune the use of tm3260 and pnx15xx series. the mmio register layout and offsets are described in section 6.3.1 . the cpu apertures (dram and apert1 described in section 2.2 ) can be modi?d by the tm3260 itself, if the tm32_apert_modifiable bit is set to ?? in host mode the host cpu can decide to prevent tm3260 to go out of its allowed apertures by ?pping to ??the bit tm32_apert_modifiable. the tm32_ls_dblline and tm32_ifu_dblline parameters in?ence the overall performance of the tm3260. these parameters are related to the cache line sizes and the optimal memory burst than can be obtained with pnx15xx series mmi. the default values favor the main memory bandwidth usage and improve, in most cases, the tm3260 processing power. however some applications may require a shorter memory burst to reduce the bandwidth usage or to avoid some pathological cache trashing cases. tm32_ls_dblline and tm32_ifu_dblline can then be ?pped to ?? there is no available formula to know if a particular application bene?s from one setting or the other. experimentation on the ?al application is recommended to determine the optimal settings. it is possible for a host cpu to shutdown entirely the high speed clock of the tm3260. the safe procedure consists in ?st requesting the tm3260 to prepare itself for major powerdown mode. the host cpu needs ?st to alert the software running on the tm3260 that a powerdown sequence is coming. the tm3260 software acknowledges that it is ready. then the host cpu toggles the tm32_pwrdwn_req bit to inform the tm3260 module that a full powerdown mode is requested. the tm3260 hardware state machine replies by asserting the tm32_pwrdwn_ack bit. from this point tm3260 will not answer to any request and its high speed cpu clock can be turned off by the cpu host. the wake-up sequence starts by turning back on the high speed cpu clock and then ?p to ??the tm32_pwrdwn_req bit. remark: it is not recommended to have the tm3260 to flip itself to ? the tm32_pwrdwn_req bit.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-16 6.3.1 tm3260 system parameters mmio registers 7. video input and output routers pnx15xx series provides two groups of high speed pins to stream data or video in and out. the input group of pins is pre?ed by vdi, video data input. the output group is pre?ed by vdo, video data output. each group is shared between two modules. on the input side, vip and fgpi get their pin allocation through the input router. on the output side qvcp and fgpo get their pin assignment through the output router. the input router is controlled by vdi_mode. the output router is controlled by the vdo_mode. table 7: tm3260 system parameters mmio registers bit symbol acces s value description system module registers offset 0x06 3700 tm32_control 31:4 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 3 tm32_apert_modifi able r/w 0x1 tm3260 aperture modi?ble. this bit is usually written once at boot time. the value of this bit can only be altered once. 0: disables writes by the tm3260 to the mmio registers tm32_dram_hi, tm32_dram_lo, tm32_apert_hi and tm32_apert_lo. 1: enables writes by the tm3260 to the mmio registers tm32_dram_hi, tm32_dram_lo, tm32_apert_hi and tm32_apert_lo. 2 tm32_ls_dblline r/w 0x1 tm3260 load/store unit (i.e. data cache) double line fill enable 0: do not enable double line ?ls for the load/store unit 1: enable double line ?ls for the load/store unit 1 tm32_ifu_dblline r/w 0x1 tm3260 instruction fetch unit (i.e. instruction cache) double line fill enable 0: do not enable double line ?ls for the instruction fetch unit 1: enable double line ?ls for the instruction fetch unit 0 tm32_pwrdwn_req r/w 0x0 tm3260 full powerdown request upon writes: 1->0: request a tm3260 power up 0->1: request a tm3260 power down upon reads unde?ed offset 0x06 3704 tm32_status 31:1 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 0 tm32_pwrdwn_ack r 0x0 0: tm3260 is in full power mode. 1: tm3260 is in full powerdown mode.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-17 section 7.1 details the vdi and vdo pin assignment based on the content of the vdi_mode and vdo_mode mmio registers. section 9.1 and section 9.2 on page 2- 19 give an overview of the different modes. 7.1 mmio registers for the input/output video/data router in the following tables the x associated with a bit value means ?o not care? (clk_vip ff) means the data is registered by the clock assigned to vip before presenting the signals to the vip module. (clk_fgpi ff) means the data is registered by the clock assigned to fgpi before presenting the signals to the fgpi module.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-18 table 8: global registers bit symbol acces s value description input and output control registers offset 0x06 3000 vdi_mode 31:8 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 7 vdi_mode_7 r/w 0 this bit should be set to ??only when fgpi is set to work in 8-bit mode. this bit controls dedicated hardware located in the input router that allows to use the fgpi module as a second module to capture a 656 video source. however in this mode there is no on-the-? video image processing possible and the yuv data is linearly stored in memory (vip uses yuv planes). the dedicated hardware allows to generate fgpi_start and fgpi_stop signals that directs fgpi to store each ?ld of the in-coming 656 video stream into a separate buffer. the description bellow explains the behavior of the state machine for that dedicated pattern matching hardware. 0: disable pattern matching state machine for fgpi start/stop signals. 1: enable pattern matching state machine for fgpi start/stop signals. when ?st enabled, the pattern matching state machine is in its ?nit?state and begins comparing fgpi_data[7:0] for the pattern 0xff, 0x00, 0x00, and 0xec on each fgpi clock. once this pattern is detected, it enters the ?ain?state. below are listed the patterns for fgpi_start and fgpi_stop signal assertion/de-assertion when in the main state. the fgpi_start signal asserts for one fgpi clock when the fourth byte of the pattern is matched. the fgpi_start signal de-asserts on the next fgpi clock and remains de-asserted until one of the patterns is detected. the fgpi_stop asserts when the assertion pattern is detected and remains asserted until the de-assertion pattern is detected. the pattern matching state machine returns to the ?nit?state when vdi_mode[7] = 0 or the fgpi block is reset with a hardware or software reset. fgpi_start = 1 when fgpi_data[7:0] =0xff, 0x00, 0x00, 0x9d or 0xff, 0x00, 0x00, 0xda or 0xff, 0x00, 0x00, 0xf1 or 0xff, 0x00, 0x00, 0xb6 else fgpi_start = 0. fgpi_stop = 1 when fgpi_data[7:0] =0xff, 0x00, 0x00, 0xf1 fgpi_stop = 0 when fgpi_data[7:0] =0xff, 0x00, 0x00, 0xb6 6:5 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-19 4:3 2 1:0 vdi_mode[4:3] vdi_mode[2] is unused vdi_mode[1:0] r/w - r/w 0 - 0 vdi-to-vip mapping xx000 : 8- or 10-bit itu 656, 8- or 10-bit raw data vdi_v1-> (clk_vip ff)-> vip_dv_valid vdi_d[29:20] -> (clk_vip ff)-> vip_dv_data[9:0] ??> vip_dv_d_data[9:0] reserved-> (clk_vip ff)-> vip_vrefhd reserved-> (clk_vip ff)-> vip_hrefhd ??> vip_frefhd in 8-bit itu 656 mode the yuv[7:0] maps to vip_dv_data[9:2], therefore it maps to vdi_d[29:22]. similarly in 8-bit raw data mode vdi_d[29:22] contains the 8-bit data. note: h/v sync can only be used when vip is operated in 8-bit vmi mode. in that mode the h/v syncs must be connected to vdi_d[20] and vdi_d[21] respectively. xx001 : 20-bit itu 656 like for hd vdi_v1-> (clk_vip ff)-> vip_dv_valid vdi_d[19:10] -> (clk_vip ff)-> vip_dv_data[9:0] vdi_d[29:20] -> (clk_vip ff)-> vip_dv_d_data[9:0] vdi_d[30]-> (clk_vip ff)-> vip_vrefhd vdi_d[31]-> (clk_vip ff)-> vip_hrefhd vdi_d[9]-> (clk_vip ff)-> vip_frefhd hd can be 10- or 8-bit yuv data. in 8-bit mode vdi_d[19:12] contains the uv data. vdi_d[29:22] is expecting the 8-bit y data. in 10-bit mode vdi_d[19:10] contains the uv bus. vdi_d[29:20] is expecting the 10-bit y data. xx010 : 8-bit itu 656 or 8-bit raw data vdi_v1-> (clk_vip ff)-> vip_dv_valid vdi_d[31:24] -> (clk_vip ff)-> vip_dv_data[9:2] ??> vip_dv_data[1:0] ??> vip_dv_d_data[9:0] ??> vip_vrefhd ??> vip_hrefhd ??> vip_frefhd xx011 : n/a vdi_v1-> (clk_vip ff)-> vip_dv_valid ??> vip_dv_data[9:0] ??> vip_dv_d_data[9:0] ??> vip_vrefhd ??> vip_hrefhd ??> vip_frefhd table 8: global registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-20 4:3 2 1:0 vdi_mode[4:3] vdi_mode[2] is unused vdi_mode[1:0] r/w - r/w 0 - 0 vdi-to-fgpi mapping up to 22-bit data capture xx000 : vdi_v2 -> (clk_fgpi ff) -> fgpi_d_valid vdi_d[15:0] -> (clk_fgpi ff) -> fgpi_data[15:0] vdi_d[32] -> (clk_fgpi ff) -> fgpi_start (*) vdi_d[33] -> (clk_fgpi ff) -> fgpi_stop (*) 00000 : ??> fgpi_data[31:20] vdi_d[19:16] -> (clk_fgpi ff) -> fpgi_data[19:16] 01000 : ??> fgpi_data[31:20] vdi_d[19:16] -> (clk_fgpi ff) -> fpgi_data[19:16] 10000 : vdi_d[19] -> (clk_fgpi ff)-> fgpi_data[31:20] vdi_d[19:16] -> (clk_fgpi ff)-> fpgi_data[19:16] 11000 : vdi_d[15] -> (clk_fgpi ff) -> fpgi_data[31:16] (*) for vdi_mode[7] = 0. when vdi_mode[7] = 1, fgpi_start and fgpi_stop are controlled by a simple pattern matching state machine. 4:3 2 1:0 vdi_mode[4:3] vdi_mode[2] is unused vdi_mode[1:0] r/w - r/w 0 - 0 vdi-to-fgpi mapping (continued) up to 12-bit data capture xx001 : vdi_v2 -> (clk_fgpi ff) -> fgpi_d_valid vdi_d[7:0] -> (clk_fgpi ff) -> fgpi_data[7:0] vdi_d[32] -> (clk_fgpi ff) -> fgpi_start (*) vdi_d[33] -> (clk_fgpi ff) -> fgpi_stop (*) 00001 : ??> fgpi_data[31:9] vdi_d[8] -> (clk_fgpi ff) -> fpgi_data[8] 01001 : ??> fgpi_data[31:9] vdi_d[8] -> (clk_fgpi ff) -> fpgi_data[8] 10001 : vdi_d[8] -> (clk_fgpi ff) -> fgpi_data[31:9] vdi_d[8] -> (clk_fgpi ff) -> fpgi_data[8] 11001 : vdi_d[7] -> (clk_fgpi ff) -> fpgi_data[31:8] (*) for vdi_mode[7] = 0. when vdi_mode[7] = 1, fgpi_start and fgpi_stop are controlled by a simple pattern matching state machine. table 8: global registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-21 vdi-to-fgpi mapping (continued) up to 24-bit data capture xx010 : vdi_v2 -> (clk_fgpi ff) -> fgpi_d_valid vdi_d[23:0] -> (clk_fgpi ff) -> fgpi_data[23:0] vdi_d[32] -> (clk_fgpi ff) -> fgpi_start (*) vdi_d[33] -> (clk_fgpi ff) -> fgpi_stop (*) 00010 : ?? -> fgpi_data[31:24] 01010 : ?? -> fgpi_data[31:24] 10010 : vdi_d[23] -> (clk_fgpi ff) -> fgpi_data[31:24] 11010: ? -> fgpi_data[31:24] (*) for vdi_mode[7] = 0. when vdi_mode[7] = 1, fgpi_start and fgpi_stop are controlled by a simple pattern matching state machine. vdi-to-fgpi mapping (continued) up to 32-bit data capture xx011: vdi_v2 -> (clk_fgpi ff) -> fgpi_d_valid vdi_d[31:0] -> (clk_fgpi ff) -> fgpi_data[31:0] vdi_d[32] -> (clk_fgpi ff) -> fgpi_start (*) vdi_d[33] -> (clk_fgpi ff) -> fgpi_stop (*) (*) for vdi_mode[7] = 0. when vdi_mode[7] = 1, fgpi_start and fgpi_stop are controlled by a simple pattern matching state machine. offset 0x06 3004 vdo_mode 31:8 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 7 vdo_mode r/w 0 if set to ??and vdo_mode[2:0] set to 0, then in addition to the qvcp to the tft interface mapping the fgpo 8-bit lsbs map as follows: vdo_d34 -> (clk_fgpo ff) -> fgpo_data[7] fgpo_buf_sync -> (clk_fgpo ff) -> fgpo_data[6] fgpo_rec_sync -> (clk_fgpo ff) -> fgpo_data[5] vdo_d33 -> (clk_fgpo ff) -> fgpo_data[4] vdo_d32 -> (clk_fgpo ff) -> fgpo_data[3] vdo_d[2:0] -> (clk_fgpo ff) -> fgpo_data[2:0] this mode allows to have, for example, a itu-656 video stream coming out of fgpo while the qvcp drives a 24-bit tft lcd panel. table 8: global registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-22 6 vdo_mode r/w 0 ?? no action ?? when vdo_mode[2:0] = 100, i.e. digital 24-bit yuv or rgb video: qvcp_data[15:12,9:2] -> vdo_d[16:5] when vdo_clk1=1 qvcp_data[29:22,19:16] -> vdo_d[16:5] when vdo_clk1=0 i.e. g[3:0], b[7:0] -> vdo_d[16:5] when vdo_clk1=1 i.e. r[7:0], g[7:4] -> vdo_d[16:5] when vdo_clk1=0 i.e. u[3:0], v[7:0] -> vdo_d[16:5] when vdo_clk1=1 i.e. y[7:0], u[7:4] -> vdo_d[16:5] when vdo_clk1=0 all the other vdo pins are mapped as described below for vdo_mode[2:0] = 100. this mode is typically used to interface with video encoders like the philips saa7104 that require the video data to be presented on both edges of the pixel clock. this mode allows to transfer the 24-bit data over a 12-bit interface, vdo_d[16:5]. note: the yuv mode does not match the saa7104 expected inputs. use the rgb mode instead. note: this mode requires a 50/50 duty cycle clock. this can be achieved by programming the qvcp pll at twice the speed and divide it by 2 by setting the p divider to 1, or use a times 4 or 8 as described in section pll settings page 5- 9 . 5 vdo_mode r/w 0 ?? no action ?? when vdo_mode[2:0] = 010, i.e. digital 16-bit yuv video: qvcp_data[19:12] -> vdo_d[20:13] when vdo_clk1=1 qvcp_data[9:2] -> vdo_d[20:13] when vdo_clk1=0 i.e. uv[7:0] -> vdo_d[20:13] when vdo_clk1=1 i.e. y[7:0] -> vdo_d[20:13] when vdo_clk1=0 all the other vdo pins are mapped as described below for vdo_mode[2:0] = 010. this mode is typically used to interface with video encoders like the philips saa7104 that require the video data to be presented on both edges of the pixel clock. this mode allows to transfer the 16-bit data over an 8-bit interface, vdo_d[20:13]. note: this mode requires a 50/50 duty cycle clock. this can be achieved by programming the qvcp pll at twice the speed and divide it by 2 by setting the p divider to 1, or use a times 4 or 8 as described in section pll settings page 5- 9 . 4:3 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. table 8: global registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-23 2:0 vdo_mode r/w 0 tft/qvcp mapping to vdo interface 000*: tft lcd controller with 24- or 18-bit digital rgb/yuv video tft_data[23:0] -> vdo_d[28:5] tft_vsync -> vdo_d[29] tft_hsync -> vdo_d[30] tft_de -> vdo_d[31] tft_vddon -> vdo_d[4] tft_bklton -> vdo_d[3] tft_clk -> vdo_clk1 in 18-bit mode vdo_d[28:23] -> r[5:0] or y[5:0] vdo_d[20:15] -> g[5:0] or u[5:0] vdo_d[12:7] -> b[5:0] or v[5:0] in 24-bit mode vdo_d[28:21] -> r[7:0] or y[5:0] vdo_d[20:13] -> g[7:0] or u[5:0] vdo_d[12:5] -> b[7:0] or v[5:0] 001*: digital itu 656 yuv 8-/10-bit qvcp_data[9:0] -> vdo_d[28:19] qvcp_vsync -> vdo_d[29] qvcp_hsync -> vdo_d[30] qvcp_aux1 -> vdo_d[31] qvcp_clk -> vdo_clk1 in 8-bit mode yuv[7:0] is mapped to vdo_d[28:21]. qvcp_aux1 can be programmed to output, a cblank signal, a field indicator or a video/graphics detector. 010*: digital 16-bit yuv video qvcp_data[19:12,9:2] -> vdo_d[28:13] qvcp_vsync -> vdo_d[29] qvcp_hsync -> vdo_d[30] qvcp_aux1 -> vdo_d[31] qvcp_clk -> vdo_clk1 y[7:0] is mapped to vdo_d[20:13]. uv[7:0] is mapped to vdo_d[28:21]. qvcp_aux1 can be programmed to output, a cblank signal, a field indicator or a video/graphics detector. 011*: digital 20-bit yuv video qvcp_data[19:10,9:0] -> vdo_d[28:9] qvcp_vsync -> vdo_d[29] qvcp_hsync -> vdo_d[30] qvcp_aux1 -> vdo_d[31] qvcp_clk -> vdo_clk1 y[9:0] is mapped to vdo_d[18:9]. uv[9:0] is mapped to vdo_d[28:19]. qvcp_aux1 can be programmed to output, a cblank signal, a field indicator or a video/graphics detector. table 8: global registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-24 100*: digital 24-bit yuv or rgb video qvcp_data[29:22,19:12,9:2] -> vdo_d[28:5] qvcp_vsync -> vdo_d[29] qvcp_hsync -> vdo_d[30] qvcp_aux1 -> vdo_d[31] qvcp_clk -> vdo_clk1 in 24-bit mode vdo_d[28:21] -> r[7:0] or y[7:0] vdo_d[20:13] -> g[7:0] or u[7:0] vdo_d[12:5] -> b[7:0] or v[7:0] in 18-bit mode vdo_d[28:23] -> r[5:0] or y[5:0] vdo_d[20:15] -> g[5:0] or u[5:0] vdo_d[12:7] -> b[5:0] or v[5:0] qvcp_aux1 can be programmed to output, a cblank signal, a field indicator or a video/graphics detector. 101*: digital 30-bit yuv or rgb video qvcp_data[29:0] -> vdo_d[32,28:0] qvcp_vsync -> vdo_d[29] qvcp_hsync -> vdo_d[30] qvcp_aux1 -> vdo_d[31] qvcp_clk -> vdo_clk1 in 30-bit mode vdo_d[32,28:20] -> r[9:0] or y[9:0] vdo_d[19:10] -> g[9:0] or u[9:0] vdo_d[9:0] -> b[9:0] or v[9:0] in 24-bit mode vdo_d[32,28:22] -> r[7:0] or y[7:0] vdo_d[19:12] -> g[7:0] or u[7:0] vdo_d[9:2] -> b[7:0] or v[7:0] in 18-bit mode vdo_d[32,28:24] -> r[5:0] or y[5:0] vdo_d[19:14] -> g[5:0] or u[5:0] vdo_d[9:4] -> b[5:0] or v[5:0] qvcp_aux1 can be programmed to output, a cblank signal, a field indicator or a video/graphics detector. 110*: digital itu 656 yuv 8-bit qvcp_data[9:2] -> vdo_d[31:24] qvcp_clk -> vdo_clk1 111*: no tft/qvcp-to-vdo mapping. table 8: global registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-25 [8-1] note: *when the lcd if is enabled, vdo_mode[2:0] is forced to ?00? 2:0 vdo_mode r/w 0 fgpo mapping to vdo interface 000* and vdo_mode[7] = ?? fgpo_data[2:0] -> vdo_d[2:0] fgpo_data[3] -> vdo_d[32] fgpo_data[4] -> vdo_d[33] fgpo_data[5] -> fgpo_rec_sync fgpo_data[6] -> fgpo_buf_sync fgpo_data[7] -> vdo_d[34] fgpo_clk -> vdo_clk2 000* and vdo_mode[7] = ?? fgpo_data[2:0] -> vdo_d[2:0] fgpo_start/rec_start -> vdo_d[32] fgpo_stop/buf_start -> vdo_d[33] fgpo_clk -> vdo_clk2 001*: fgpo_data[18:0] -> vdo_d[18:0] fgpo_start/rec_start -> vdo_d[32] fgpo_stop/buf_start -> vdo_d[33] fgpo_clk -> vdo_clk2 010*: fgpo_data[12:0] -> vdo_d[12:0] fgpo_start/rec_start -> vdo_d[32] fgpo_stop/buf_start -> vdo_d[33] fgpo_clk -> vdo_clk2 011*: fgpo_data[8:0] -> vdo_d[8:0] fgpo_start/rec_start -> vdo_d[32] fgpo_stop/buf_start -> vdo_d[33] fgpo_clk -> vdo_clk2 100*: fgpo_data[4:0] -> vdo_d[4:0] fgpo_start/rec_start -> vdo_d[32] fgpo_stop/buf_start -> vdo_d[33] fgpo_clk -> vdo_clk2 101*: no fgpo-to-vdo mapping. 110*: fgpo_data[23:0] -> vdo_d[23:0] fgpo_start/rec_start -> vdo_d[32] fgpo_stop/buf_start -> vdo_d[33] fgpo_clk -> vdo_clk2 111*: fgpo_data[31:0] -> vdo_d[31:0] fgpo_start/rec_start -> vdo_d[32] fgpo_stop/buf_start -> vdo_d[33] fgpo_clk -> vdo_clk2 table 8: global registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-26 8. miscellaneous several other system mmio registers are described in the following paragraphs and detailed in the next section 8.1 : by default pci_inta_n is an input/output pin used in open drain mode for the pci bus. when a host cpu wants to assert an interrupt to the tm3260 it asserts the pci_inta_n low. similarly if tm3260 wants to notify a host cpu of an interrupt it can assert low the pci_inta_n pin by programming the pci_inta mmio register. the 8 scratch mmio registers are mainly used for debug purpose. since they are not reset by the external por_in_n or reset_in_n signals they can be used for post-mortem system crash to retain some critical or debug values. event timestamping for the spdi interface comes with a diversity of requirements. to keep pnx15xx series as a programmable system, a system multiplexer is implemented to select which event or signal to timestamp. the multiplexer is controlled by the spdi_mux_sel mmio register. the different selectable signals coming from the spdi module are displayed in section 8.1 . the spare_ctrl mmio register is reserved for future usage.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-27 8.1 miscellaneous system mmio registers table 9: miscellaneous system mmio registers bit symbol acces s value description system registers offset 0x06 3050 pci_inta 31:2 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 1 pci_inta w 0x1 writes pci_inta_n pin value if pci_inta_oe is enabled 0: pci_inta_n is 0 (asserted) 1: pci_inta_n is 1 (de-asserted) to read the pci_inta_n pin value use ipending mmio register. 0 pci_inta_oe r/w 0x0 enable of pci_inta_n output 0: disable pci_inta_n output 1: enable pci_inta_n output note: in order to operate the pci_inta_n pin as an open drain pin as required by the pci speci?ation, the software must enable the output only when driving a ?? i.e. asserting an interrupt. note: in order to avoid a race condition between the data and the enable or glitches on the pci_inta_n pin, the enable should only be changed once the data is stable. offset 0x06 3500 scratch0 31:0 scratch0 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes. offset 0x06 3504 scratch1 31:0 scratch1 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes. offset 0x06 3508 scratch2 31:0 scratch2 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes. offset 0x06 350c scratch3 31:0 scratch3 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes. offset 0x06 3510 scratch4 31:0 scratch4 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes. offset 0x06 3514 scratch5 31:0 scratch5 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes. offset 0x06 3518 scratch6 31:0 scratch6 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes. offset 0x06 351c scratch7 31:0 scratch7 r/w - 32-bit writable and readable register. not cleared at reset for debug purposes.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-28 offset 0x06 3600 spdi_mux_sel 31:4 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 3:0 spdi_mux_sel r/w 0x0 spdif in timestamping, the speci? events that may be timestamped are 0000: ws - word strobe 0001: sws - last sub-frame 0010: spdi_status[0] - buffer 1 full. 0011: spdi_status[1] - buffer 2 full. 0100: spdi_status[2] - buffer 1 active. 0101: spdi_status[3] - bandwidth error. 0110: spdi_status[4] - parity error. 0111: spdi_status[5] - validity error. 1000: spdi_status[6] - user/channel bits available. 1001: spdi_status[7] - unlock active. 1010-1111: ws - word strobe offset 0x06 360c spare_ctrl 31:8 unused - - to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 7:0 spare_ctrl r/w - spare control register. table 9: miscellaneous system mmio registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-29 9. system registers map summary table 10: system registers map summary offset name description 0x06_3000 vdi _mode video/data input router control register. 0x06_3004 vdo_mode video/data output router control register. 0x06_3014 sys_endianess system endian mode register. 0x06_3050 pci_inta pci_inta_n pin control register. 0x06_3200 dcs_dram_lo 16-bit dcs-to-mtl memory range low register. 0x06_3204 dcs_dram_hi 16-bit dcs-to-mtl memory range high register. 0x06_3208 aperture_we write enable register for dcs_dram_hi and dcs_dram_lo registers. 0x06_3500 scratch0 32-bit writable and readable register. 0x06_3504 scratch1 32-bit writable and readable register. 0x06_3508 scratch2 32-bit writable and readable register. 0x06_350c scratch3 32-bit writable and readable register. 0x06_3510 scratch4 32-bit writable and readable register. 0x06_3514 scratch5 32-bit writable and readable register. 0x06_3518 scratch6 32-bit writable and readable register. 0x06_351c scratch7 32-bit writable and readable register. 0x06_3600 spdi_mux_sel spdif in timestamping multiplexer select register. 0x06_360c spare_ctrl spare control register. 0x06_3700 tm32_control tm3260 control register. 0x06_3704 tm32_status tm3260 status register. 0x06_3800 semaphore0 12-bit semaphore register. 0x06_3804 semaphore1 12-bit semaphore register. 0x06_3808 semaphore2 12-bit semaphore register. 0x06_380c semaphore3 12-bit semaphore register. 0x06_3810 semaphore4 12-bit semaphore register. 0x06_3814 semaphore5 12-bit semaphore register. 0x06_3818 semaphore6 12-bit semaphore register. 0x06_381c semaphore7 12-bit semaphore register. 0x06_3820 semaphore8 12-bit semaphore register. 0x06_3824 semaphore9 12-bit semaphore register. 0x06_3828 semaphore10 12-bit semaphore register. 0x06_382c semaphore11 12-bit semaphore register. 0x06_3830 semaphore12 12-bit semaphore register. 0x06_3834 semaphore13 12-bit semaphore register. 0x06_3838 semaphore14 12-bit semaphore register.
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-30 10. simpli?d internal bus infrastructure more details on the dcs bus in chapter 30 dcs netw or k . 0x06_383c semaphore15 12-bit semaphore register. 0x06_3ff4 glb_reg_pwr_dwn power down bit for the global registers 0x06_3ffc glb_reg_mod _id module identi?ation and revision information figure 3: simpli?d internal bus infrastructure table 10: system registers map summary ?ontinued offset name description dcs gate and dcs bus controller boot tmdbg spdo mbs 2d-de tm3260 reset i 2 c qvcp-lcd fgpo ai spdi mac 10/100 fgpi vip mmi ao vld dvd-css pci gpio system internal mtl bus internal dcs bus pnx15xx
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-31 11. mmio memory map each module has an address range in the mmio aperture from which its registers can be accessed. this address range is de?ed by its starting address, a.k.a. its offset, and the aperture size de?ed in the module_id mmio register. the following table gives the offset position for each module of the pnx15xx series system. each module speci?ation contains the internal registers location within its aperture. therefore the physical address of each mmio register in the system is de?ed by the equation: mmio_base + module offset + register offset. table 11: mmio memory map address offset from mmio_base (pci base 14) module name module id major module revision minor module revision mmio size summary 0x04,0000 pci/xio 0xa051 0x0 0x1 0x00 pci and xio (flash, 68k, ide) status/control 0x04,5000 iic 0x0105 0x0 0x3 0x00 i 2 c for boot & devices up to 400 khz 0x04,7000 clock 0xa063 0x0 0x0 0x00 pnx15xx series modules clock control & status 0x04,f000 2d de 0x0117 0x2 0x0 0x10 2d drawing engine, includes ram area 0x06,0000 reset 0xa064 0x0 0x1 0x00 endian mode control, system & peripheral reset control/status, watchdog 0x06,1000 tmdbg 0x0127 0x0 0x0 0x00 tm software debug through jtag 0x06,3000 global 0x0126 0x8 0x1 0x00 global mmio registers controlling miscellaneous settings, input & output router settings. 0x06,4000 arbiter 0x1010 0x0 0x0 0x00 arbiter 0x06,5000 ddr ctrl 0x2031 0x1 0x1 0x00 main memory interface 0x07,0000 fgpi 0x014b 0x0 0x1 0x00 fast generic parallel input 0x07,1000 fgpo 0x014c 0x0 0x2 0x00 fast generic parallel output 0x07,2000 lan100 0x3902 0x1 0x1 0x00 10/100 lan controller 0x07,3000 lcd ctrl 0xa050 0x0 0x0 0x00 lcd controller 0x07,5000 vld 0x014d 0x0 0x0 0x00 variable length decoder 0x10,0000 tm3260 0x2b80 0x4 0x0 0x01 tm3260 cpu control/status registers 0x10,3000 dcs bus ctrl 0xa049 0x0 0x0 0x00 mmio bus controller
philips semiconductors pnx15xx series volume 1 of 1 chapter 3: system on chip resources 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 3-32 12. references [1] ?he tm3260 architecture databook? oct. 13 2003, philips. 0x10,4000 gpio 0xa065 0x0 0x1 0x00 gpio general purpose software serial i/o pins 0x10,6000 vip 0x011a 0x3 0x0 0x00 video input 0x10,9000 spdif out 0x0121 0x0 0x1 0x00 sony philips digital interface for serial audio 0x10,a000 spdif in 0x0110 0x0 0x1 0x00 sony philips digital interface for serial audio 0x10,c000 mbs 0x0119 0x2 0x8 0x00 memory based scaler 0x10,e000 qvcp 0xa052 0x0 0x1 0x00 quality video composition processor (2 layers) 0x11,0000 ao 0x0120 0x0 0x2 0x00 audio output (8 channels) 0x11,1000 ai 0x010d 0x1 0x1 0x00 audio input (8 channels) 0x1f,0000 tm3260 n/a n/a n/a 0x0f tm3260 cache tags table 11: mmio memory map address offset from mmio_base (pci base 14) module name module id major module revision minor module revision mmio size summary
1. introduction the reset module initiates life for the pnx15xx series system since it generates all reset signals required for a correct initialization of the entire system (may include board devices). it sends reset signals to all dcs bus modules and the tm3260 cpu. it sends a reset signal on the sys_rst_out_n pin that can be used by external board devices. this signal is then de-asserted by software. these resets signals are triggered by hardware (one type) or by software (three types): hardware external reset input to the pnx15xx series through the pins, por_in_n or reset_in_n. software assert and release of the sys_rst_out_n reset pin through a write to an mmio register write. software programmable watchdog timer which asserts the same reset signals as the hardware reset induced by the assertion of reset_in_n pin when a time-out is reached. software pnx15xx series system reset which asserts the same reset signals as the hardware reset induced by the assertion of reset_in_n pin. rst_cause mmio register holds the cause of the previous reset which allows the software to know what happened before. 2. functional description the reset module generates three different reset signals to fully initialize a pnx15xx series system: jtag_rst_n. this signal is used internally to reset the jtag state machine. the signal is only asserted if the por_in_n pin is asserted. therefore the only mean to reset the jtag state machine of pnx15xx series is by asserting the por_in_n pin. figure 1 remark: the jtag state machine can also be reset through the jtag pins. chapter 4: reset pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-2 peri_rst_n. this signal is used internally to reset all the pnx15xx series modules including the tm3260 cpu. this signal is asserted when one of the following conditions occurs: the por_in_n pin is asserted. the reset_in_n pin is asserted. the watchdog timer reaches a time-out, section 2.2 . a software reset is asserted, section 2.3 . remark: this signal does not reset the jtag state machine, i.e. it does not assert jtag_rst_n. sys_rst_out_n. this signal is sent to the sys_rst_out_n pin and provides a software and hardware solution to reset external devices present on a pnx15xx series system board. this signal is asserted when one of the following conditions occurs: the por_in_n pin is asserted. the reset_in_n pin is asserted. the watchdog timer reaches a time-out, section 2.2 . a software reset is asserted, section 2.3 . a software external reset is requested, section 2.4 in the following the pnx15xx series system reset refers to the assertion of peri_rst_n and sys_rst_out_n signals.
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-3 figure 1 shows an overview of the reset module connections to the remaining of the pnx15xx series system. 2.1 reset_in_n or por_in_n? por_in_n is meant to be used at power up of the system. by asserting this pin low as soon as the power sequencing starts ensures limited (if not none) contentions inside the pnx15xx series system as well as the pnx15xx series pin level. furthermore by resetting the jtag state machine the por_in_n signal ensures the pnx15xx series pins start with the correct mode. this is the cold reset and must always be connected. reset_in_n is complementary to the por_in_n signal and could be referenced as the warm reset. a typical application where the feature can be used is a system board where the jtag boundary scan is to be used to reset pnx15xx series without executing a full power down and up sequence. in this case the pnx15xx series jtag state machine should not be reset. since all pnx15xx series pins can become outputs in boundary scan mode it is possible to assert a 0 on the reset_in_n pin while the pnx15xx series system is still under the control of the internal jtag state machine. this pin may not be connected at board level. figure 1: reset module block diagram module 1 int_rst1_n int_rst2_n reset module dcs bus module 2 int_rst_n module n jtag_rst_n peri_rst_n rst_ctl rst_cause registers sys_rst_out_n reset_in_n (to off-chip devices) bus interface watch dog timer interrupt counter test block por_in_n int_rst_n tm3260 int_rst_n
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-4 2.2 the watchdog timer the internal pnx15xx series watchdog timer has two operating modes. both modes result in the assertion of the internal reset signals, peri_rst_n and sys_rst_out_n signals based upon a time-out condition. the modes are referenced as the non interrupt mode and the interrupt mode. 2.2.1 the non interrupt mode in this mode, the watchdog timer operates as a simple counter. the counter operates with the dcs clock also called mmio clock (clk_dtl_mmio). by default, i.e. after a pnx15xx series system reset, this watchdog counter is not active. the activation is done by writing a value different than 0x0 to the watchdog_count mmio register. upon that write, an internal counter of the watchdog timer is reset to 0x0 and starts to count. if the internal counter reaches the watchdog_count value then peri_rst_n and sys_rst_out_n internal reset signals are asserted and the pnx15xx series system is reset. the reset follows then the regular software reset timing, section 3.2 . if the cpu writes a 0x0 value to the watchdog_count mmio register before the internal counter reaches the previous watchdog_count value then the internal reset signals are not generated and the internal counter stops counting. similarly if the cpu writes a value different than 0x0 then the internal counter is reset to 0x0 and starts to count to the new watchdog_count value. this mode requires the cpu to come back in time to reset the internal counter on a regular basis. tm3260 software may use some of its internal hardware timers [1] to reset on time on the internal counter. the interrupt handler needs to ?st write a 0x0 value to the watchdog_count register then write a new count value. the layout of the watchdog_count mmio register is presented in section 4. . the following summarizes the sequence of operations 1. start the internal counter by writing a nonzero value to the watchdog_count mmio register. 2. a write with 0x0 value to the watchdog_count mmio register will stop the count. for continuous watchdog timer operation it is not required to write 0x0 ?st but instead start back directly from step 1). 3. if step 2 does not occur before the count reaches the watchdog_count value the pnx15xx series system reset is asserted.
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-5 the following figure 2 pictures the events. 2.2.2 the interrupt mode in this mode, the watchdog timer generates ?st an interrupt to the tm3260 before a pnx15xx series system reset is generated (when a time-out occurs because the tm3260 does not answer in time to the interrupt). the sequence of operations is similar to the non interrupt mode. first tm3260 cpu writes a value different than 0x0 to the watchdog_count mmio register. this starts an internal counter from the value 0x0. when the internal counter reaches the watchdog_count value an interrupt, source 42 (see section 6.2 on page 3- 14 ) is asserted. from here a second internal counter is started. if this second counter reaches the value previously stored into the interrupt_count mmio register then a pnx15xx series system reset is asserted. the reset follows then the regular software reset timing, section 3.2 . if the tm3260 cpu clears the pending interrupt by writing to the interrupt_clear mmio register, then the pnx15xx series system reset is not generated. the following summarizes the sequence of operations 1. enable the watchdog interrupt. this includes proper set-up of tm3260 internal interrupt controller[1] as well as an enable of the interrupt_enable mmio register. 2. initialize the interrupt_count mmio register with the maximum interrupt latency authorized before a pnx15xx series reset is asserted. 3. start the ?st counter by writing a nonzero value to the watchdog_count mmio register. 4. a write with 0x0 value to the watchdog_count mmio register will stop the count. however this is not intended to be used as such. remark: a write of any nonzero value other than the current value will reset the count. however this is not intended to be used as such. figure 2: watchdog in non interrupt mode sys_rst_out_n // clk_dtl_mmio 0ff fe fd 0 123 watchdog_count 4 5 watchdog_reset peri_rst_n sys_rst_out_n // // // // 1 2 3 4 1: the watchdog count register is programmed 2: the count is happening 3: the count reaches the programmed value and a watchdog reset is issued 4: both the internal and the external resets are asserted
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-6 5. if step 4 does not occur before the count reaches the watchdog_count value an interrupt is issued to the tm3260 cpu and the second internal counter (the interrupt counter) starts. the internal watchdog counter is reset and waits the interrupt to be cleared. 6. a write with 0x1 to interrupt_clear stops the interrupt counter and restarts the watchdog counter. therefore for continuous watchdog timer operation start back at step 5). here once the interrupt is asserted then the ?st counter is reset to zero 7. the interrupt counter reaches the interrupt_count value, the pnx15xx series system reset is asserted. the counters operate with the dcs clock also called mmio clock (clk_dtl_mmio). the following figure 3 pictures the events. 2.3 the software reset the software reset is started by writing a 0x1 to rst.ctl.do_sw_rst bit. the reset follows then the regular software reset timing, section 3.2 . 2.4 the external software reset the signal sys_rst_out_n signal can be asserted by writing a 0x1 to the rst_ctl.assert_sys_rst_out bit. the signal sys_rst_out_n signal can be de-asserted by writing a 0x1 to the rst_ctl.rel_sys_rst_out bit. figure 3: watchdog in interrupt mode // 0 12 // // // // sys_rst_out_n clk_dtl_mmio watchdog_reset peri_rst_n sys_rst_out_n 1 2 3 4 1: the interrupt is enabled then the watchdog count and the interrupt count registers are programmed. 2: the interrupt count is happening. 3: the interrupt count reaches the programmed value and a time out interrupt pulse is issued to the cpu. ff fe 0 // 12 0 0 60 // // // // // // // time_out_int_pls interrupt_count watchdog_count 5 6 4: the watchdog counter begins. 5: the interrupt has not been cleared. a watchdog reset is issued. 6: the internal and external resets are asserted.
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-7 remark: upon any of the described ways to reset the pnx15xx series system the sys_rst_out_n remains asserted until a write with 0x1 occurs to the rst_ctl.rel_sys_rst_out bit. 3. timing description 3.1 the hardware timing the assertion of por_in_n or reset_in_n signals causes the assertion of peri_rst_n, sys_rst_out_n and jtag_rst_n (only when por_in_n is asserted). see figure 4 . when the clock module receives the peri_rst_n signal, it ensures that all the pnx15xx series modules receive the 27 mhz crystal oscillator input. the 27 mhz clock remains active for all the modules until the registers in the clock module are programmed to switch from 27 mhz to their functional module clocks (either by the boot scripts or by the tm3260). the use of this generic 27 mhz clock allow all the modules to be reset synchronously. after de-asserting the reset_in_n pin, the peri_rst_n is also de-asserted and all modules release their internal resets synchronously. the plls come up to their default values while por_in_n or reset_in_n are asserted. the clock module will safely (i.e. glitch free) switch clocks from the 27 mhz clock to the separate module functional clocks. figure 4 details the hardware reset. only por_in_n is shown. the reset sequence is exactly the same when reset_in_n is asserted except that in that case the jtag_rst_n signal is not asserted. figure 4: por_in_n timing and reset sequence vdd por_in_n peri_rst_n sys_rst_out_n module clocks trst = 100 s (min) 27 mhz 1 2 3 4 5 1. por_in_n is asserted for 100 s (min) after power stable. peri_rst_n and jtag_rst_n follows the assertion and the release of por_in_n. the clock module kicks off 27 mhz clock to all modules. 2. all module resets sync to 27 mhz and all modules are reset at the same time. the boot script can now kic k jtag_rst_n 6 released by by boot module clocks switched
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-8 3.2 the software timing whenever a watchdog timer time-out occurs or when a software reset is requested by writing to the rst_ctl.do_sw_rst bit the pnx15xx series system is reset. both are referred as software reset. as seen in the previous section 3.1 it is required to hold the por_in_n or the reset_in_n signal for at least 100 s. therefore the software reset mechanism implements an internal counter that allows to assert the peri_rst_n signal for 100 s. similarly to the hardware reset the sys_rst_out_n is also asserted until the tm3260 cpu releases it. the internal counter uses the initial 27 mhz to estimate 100 s.
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-9 4. register de?itions table 1: reset module bit symbol acces s value description reset module offset 0x06,0000 rst_ctl 31:3 unused w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 2 do_sw_rst w 0 0 = no action 1 = do software reset. 1 rel_sys_rst_out w 0 0 = no action 1 = release system reset of external peripherals. 0 assert_sys_rst_o ut w 0 0 = no action 1 = do system reset of external peripherals. offset 0x06,0004 rst_cause remark: rst_ctl is set on every time an hardware or software reset occurs. 31:2 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 1:0 rst_cause r n/a reset cause register: 00 = cause is external system reset, reset_in_n. 01 = cause is software system reset. 10 = cause is external system reset, por_in_n 11 = cause is watchdog time-out. note if multiple resets occur then only the one that is highest in the above order will be registered. as an example reset_in_n (00) and por_in_n (10) are both asserted. a read would return ?0 offset 0x06,0008 watchdog_count 31:0 watchdog_count r/w 0 value to count to in order to either assert an interrupt (interrupt mode) or a reset (non interrupt mode) offset 0x06,000c interrupt_count 31:0 interrupt_count r/w 0 value to count to after the interrupt is asserted before asserting the system reset offset 0x06,0fe0 interrupt status 31:1 unused r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 watchdog_interru pt r 0 1: watchdog interrupt is asserted offset 0x06,0fe4 interrupt_enable 31:1 unused r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 watchdog_interru pt_enable r/w 0 1: interrupt enabled 0: interrupt not enabled offset 0x06,0fe8 interrupt_clear 31:1 unused r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read.
philips semiconductors pnx15xx series volume 1 of 1 chapter 4: reset 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 4-10 5. references [1] ?he tm3260 architecture databook? aug. 1st 2003, philips. 0 watchdog_interru pt_clear r/w 0 1: clear interrupt offset 0x06,0fec interrupt_set 31:1 unused r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 watchdog_interru pt_set r/w 0 1: set interrupt offset 0x06,0ffc module_id 31:16 module_id r 0xa064 reset module id 15:12 major_rev r 0x0 changed upon functional revision, like new feature added to previous revision 11:8 minor_rev r 0x1 changed upon bug ? or non functional changes like yield improvement. 7:0 aperture r 0x0 encoded as: aperture size = 4k*(bit_value+1). the bit value is reset to 0 meaning a 4k aperture for the global register 1 module according to the formula above. table 1: reset module ?ontinued bit symbol acces s value description
1. introduction the clock module is the heart of the pnx15xx series system. its role is to provide and control all the clocks of the system. the main characteristics of the clock module is to be low cost. it generates all the pnx15xx series system clocks from one unique source, a 27 mhz input crystal. the clock module features can be regrouped as follows: use of phase locked loop (pll) circuits, direct digital synthesizers (dds) or simple clock dividers to meet the frequency and jitter requirements of all pnx15xx series modules. all the clocks are software programmable and support powerdown features. clock switching or clock frequency changes occur glitch free thank to dedicated hardware. 2. functional description the clock module has three main internal interfaces: an interface to a custom analog block (cab). the cab module includes 2 plls, several high speed clock dividers and 9 dds blocks. an interface to a dedicated low jitter pll used for the ddr memory controller. an mmio interface to allow the programming of all con?uration registers. a 27 mhz crystal clock provides the source clock for all plls in the cab block and for the low jitter pll. the plls are programmable from the clock module registers to generate a range of possible frequencies. the dds blocks are required to make slight adjustments to each video and audio clock to track transmission sources. software controls this tracking by programming the relevant dds block to adjust the clock. these adjustments are made in steps of 0.4 hz. the dds clocks are derived from the internal 1.728 ghz pll (64 times the 27 mhz input crystal). the dds jitter is less than 0.58 ns. the video clock requirements may require a shorter term jitter so an additional pll is provided to smooth out the dds jitter. this combines the two video clock requirements, low jitter and high precision adjustment of the clock frequency to meet color burst requirements but also track the audio signals. the clock module consists of an mmio-interface with programmable clock and pll control registers, and a series of control logic for every clock generated. the clock control logic will consist of: chapter 5: the clock module pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-2 programmable dividers, controlled by con?uration registers clock blocking circuitry to allow for safe, glitch-free switching of clocks. clocks are typically switched when: plls or dividers are reprogrammed clocks are switched on/off for powerdown reasons following reset and boot-up of the chip when all clocks are switched from 27 mhz to their programmed functional frequencies design for debug (dfd) features e.g. clock stretching, section 2.6 .
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-3 figure 1 shows a block diagram of the clock module. additional design for test (dft) have been added into the drawing and can be disregarded for functional behavior. the signals in red are for ate purpose and are disabled in normal functional operating mode. figure 1: clock module block diagram xtali xtalo en oscillator pad 1.728 ghz pll0 dds4 dds custom analog block (cab) tps_clocks mmio-interface & control regs xtal_clk divider dds2 dds0 dds3 dds5 dds7 dds6 dds8 divider mmio-bus clock to modules clock to modules tst_clk reset_in_n dft logic tst_clk_enable pll1_7_fb bypass dds ccb_si ccb_so tst_ccb_shift slice sel_div_tst dds_tst_bypass slice tst_clk_mem tst_clk_fpi slice_test_in slice_test_out tst_cab_bypass /2 clk_dds_tst (analog pad) clk_mem pll1 dds1 pll2 low jitter pll (external to cab) msb in ddsx_ctl registers selects test input on dds
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-4 remark: not all the clocks to the modules are generated in the clock module, there will be other clocks which will come into pnx15xx series from external sources. some of these clocks will be fed through the clock module so that they may undergo the same controls required during reset, powerdown, dft and dfd. 2.1 the modules and their clocks t ab le 1 presents a summary of all the clocks used in the pnx15xx series system. the table is organized with the module name, the corresponding internal clock signal name, a brief description, the operating frequency range or the available clock speeds, the mmio registers that control the clock selection and the ?tandard?clock used. the ?tandard?clock used is the recommended clock use when all the clock generation capabilities are used. this is based on common board systems, however it is possible to use other clock sources. see section 3. on page 5- 31 for mmio registers layout. t ab le 1 can be used as a quick reference to see the pnx15xx series clocking capabilities. table 1: pnx15xx series module and bus clocks bus or module signal name description frequencies mmio clock module control register(s) standard clock source ddr sdram clk_mem mm_clk up to 200 mhz pll2_ctl clk_mem_ctl pll2 tm3260 cpu clk_tm the tm3260 clock up to 300 mhz depending on speed grade pll0_ctl dds0_ctl clk_tm_ctl pll0, fed by the input 27 mhz crystal) mmio clk_dtl_mmio mmio clock or dcs clock 157 mhz 144 mhz 133 mhz 123 mhz 115 mhz 108 mhz 102 mhz 54 mhz clk_dtl_mmio_ctl 1.728 ghz dividers 2dde clk_2dde 2d drawing engine clock 144 mhz 123 mhz 108 mhz 96 mhz 86 mhz 78 mhz 72 mhz 66 mhz clk_2dde_ctl 1.728 ghz dividers pci clk_pci pci_sys_clk 33.23 mhz clk_pci_ctl the pci module gets its primary clock directly from the pci_clk pin. n/a
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-5 mbs clk_mbs mbs clock 144 mhz 123 mhz 108 mhz 96 mhz 86 mhz 78 mhz 72 mhz 66 mhz clk_mbs_ctl 1.728 ghz dividers tmdbg gpio clk_tstamp timestamp clock 108 mhz clk_tstamp_ctl 1.728 ghz dividers 10/100 ethernet mac clk_lan ethernet phy clock up to 50 mhz clk_lan_ctl and pll1_ctl and dds1_ctl or dds4_ctl or dds7_ctl dds7 clk_lan_tx ethernet transmit clock up to 27 mhz clk_lan_tx_ctl external clk_lan_rx ethernet receiver clock up to 27 mhz clk_lan_rx_ctl external iic clk_iic i 2 c module clock 24 mhz clk_iic1_ctl 1.728 ghz dividers scl1_out iic_scl pin 24 mhz/ nn is controlled by the i 2 c module to generate an up to 400 khz clock. internal dvdd clk_dvdd dvdd block 144 mhz 123 mhz 108 mhz 96 mhz 86 mhz 78 mhz 72 mhz 54 mhz clk_dvdd_ctl 1.728 ghz dividers table 1: pnx15xx series module and bus clocks bus or module signal name description frequencies mmio clock module control register(s) standard clock source
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-6 qvcp clk_qvcp_out vdo_clk1 external pixel clock up to 81 mhz typical values: 27 mhz 54 mhz 65 mhz pll1_ctl dds1_ctl clk_qvcp_ctl smoothing dds1/pll1 combination clk_qvcp_pix internal pixel clock up to 50 mhz clk_qvcp_pix_ctl internal clk_qvcp_proc processing layer clock 144 mhz 133 mhz 108 mhz 96 mhz 86 mhz 78 mhz 58 mhz 39 mhz 33 mhz 17 mhz clk_qvcp_proc_ctl maximum speed supported is 96 mhz. other higher speeds are reserved for future use. 1.728 ghz dividers clk_lcd_tstamp lcd timestamp 27 mhz n/a vip clk_vip vdi_clk1 external pixel clock up to 81 mhz dds7_ctl clk_vip_ctl external vld clk_vld mpeg-2 variable length decoder 144 mhz 133 mhz 108 mhz 96 mhz 86 mhz 78 mhz 72 mhz 66 mhz clk_vld_ctl 1.728 ghz dividers ai ai_osclk ao_osclk external oversampling clock up to 50 mhz dds4_ctl ai_osclk_ctl dds4 ai_sck up to 25 mhz ai_sck_ctl external or internal ao ao_osclk ai_osclk external oversampling clock up to 50 mhz pll1_ctl and dds1_ctl or dds3_ctl ao_osclk_ctl dds3 ao_sck up to 25 mhz ao_sck_ctl external or internal table 1: pnx15xx series module and bus clocks bus or module signal name description frequencies mmio clock module control register(s) standard clock source
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-7 2.2 clock sources for pnx15xx series all clocks in the pnx15xx series clock system are generated from 5 possible sources: 2 identical plls within the cab block 1 separate pll for the memory system called pll2 high frequency dividers from the 1.728 ghz pll in the cab the dds blocks within the cab external clock inputs, or derived from input data streams gpio clk_gpio_4q gpio fifo clock up to 108 mhz dds8_ctl dds8 clk_gpio_5q gpio fifo clock up to 108 mhz dds7_ctl clk_gpio_6q_12 gpio fifo clock/ external clock up to 108 mhz dds6_ctl dds6 clk_gpio_13 external clock up to 108 mhz dds5_ctl clk_gpio_14 external clock up to 108 mhz dds2_ctl - spdio clk_spdo spdo module clock up to 40 mhz dds5_ctl clk_spdo_ctl dds5 clk_spdi spdi module clock 72 mhz 144 mhz clk_spdi_ctl 1.728 ghz dividers fgpi clk_fgpi up to 100 mhz dds3_ctl or dds8_ctl clk_fgpi_ctl dds8 fgpo clk_fgpo up to 100 mhz pll1_ctl and dds1_ctl or dds2_ctl clk_fgpo_ctl dds2 table 1: pnx15xx series module and bus clocks bus or module signal name description frequencies mmio clock module control register(s) standard clock source
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-8 2.2.1 pll speci?ation a pll consists of a voltage controlled oscillator (vco) and a post divide (pd) circuit, as presented in figure 2 . the frequency from the vco, f vco can be determined as follows: (1) f vco can be post divided by 1, 2, 4 and 8 according to the following equation: (2) the bit width of n, m, p is 9, 5 and 2 bits respectively. the n, m and p bits are programmable register bits in the clock module control registers, pll0_ctl and pll1_ctl. pll2_ctl does not allow to control the p parameter since it is ?ed to ?? i.e. divides f vco by 2, to ensure a 50% duty cycle clock on the ddr sdram interface. remark: using a value of 0 for either m or n could lead to undesirable behavior. for that reason, setting either m or n to 0 will result in a value of 1 being used for both m and n. assuming the p value is set to 0, this will result in a pll output frequency of 27 mhz. pll limitations the following equations must be met (3) (4) (5) general recommendations keep m with low values figure 2: pll block diagram /m /p /n pd loop filter vco clk_out clk_in extracted for dft pll (xtal_clk) 9 5 2 fin fpd fvco fout f vco 27mhz n m - --- - = f out f vc o 2 p ------- --- - = 2mhz f in 150mhz ? 100mhz f vco 600mhz ? 2mhz f pd 27mhz ?
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-9 run the vco as high as possible, therefore for low output frequencies chose high p values ensure and track n with the following current adjustment values: pll settings an easy way to determine the n over m ratio is to meet the pll limitations seen above and solve the following equation: (6) pll setting examples t ab le 1 presents some other typical examples to set the pll n, m and p parameters. pll2 (for the ddr) has the p parameter wired to ?? 30 n 180 ? table 2: current adjustment values based on n 30-37 38-46 47-54 55-63 64-72 73-82 83-89 90-97 98-107 108-116 117-125 126-133 134-142 143-151 152-160 161-180 0xf 0xe 0xd 0xc 0xb 0xa 0x9 0x8 0x7 0x6 0x5 0x4 0x3 0x2 0x1 0x0 n m - --- - f vc o f in ------- --- - = table 3: pll setting examples f out f vco f in m n p adj destination examples 27 mhz 216 mhz dds1 27 mhz 4 0x20 3 0xf qvcp from dds1 50% duty cycle recommended 54 mhz 432 mhz dds1 27 mhz 3 0x30 3 0xd qvcp from dds1 50% duty cycle recommended 65 mhz 520 mhz dds1 27.012987 mhz 4 0x4d 3 0xa qvcp from dds1 50% duty cycle recommended 81 mhz 324 mhz dds1 27 mhz 3 0x24 2 0xf qvcp from dds1 50% duty cycle recommended 133.07 mhz 266.14 mhz 27 mhz crystal 7 0x45 1 0xb ddr266, i.e. < 133.333333 mhz mm_ck 166.5 mhz 333 mhz 27 mhz crystal 3 0x25 1 0xf ddr333, i.e. < 166.666666 mhz mm_ck 199.8 mhz 399.6 mhz 27 mhz crystal 5 0x4a 1 0xa ddr400, i.e. < 200 mhz mm_ck 266.63 mhz 533.25 mhz 27 mhz crystal 4 0x4f 1 0xa 266 mhz tm3260 300.38 mhz 600.75 mhz 27 mhz crystal 4 0x59 1 0x9 300 mhz tm3260
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-10 pll characteristics 2.2.2 the clock dividers the clock dividers allow to generate internally low jitter ?ed clocks derived from the 1.728 ghz pll. resulting jitter is higher than the pll jitter but remains less than 200 ps. t ab le 5 shows the 22 available internal clocks. table 4: pll characteristics pll data input clock frequency vco input frequency vco output frequency output frequency jitter (high frequency) < 150 ps lock time < 100 s duty cycle 50-50 (with p=1, 2, 3) [37,63]-[63,37] (with p=0) 2mhz f in 150mhz ? 3mhz f pd 27mhz ? 100mhz f vco 600mhz ? 50mhz f out 600mhz ? table 5: internal clock dividers clock name clock source divider value exact frequency clk_192 1.728 ghz 9 192 mhz clk_173 1.728 ghz 10 172.8 mhz clk_157 1.728 ghz 11 157.0909 mhz clk_144 1.728 ghz 12 144 mhz clk_133 1.728 ghz 13 132.9231 mhz clk_123 1.728 ghz 14 123.4286 mhz clk_115 1.728 ghz 15 115.2 mhz clk_108 1.728 ghz 16 108 mhz clk_102 1.728 ghz 17 101.6471 mhz clk_96 clk_192 2 96 mhz clk_86 clk_173 2 86.4 mhz clk_78 clk_157 2 78.54545 mhz clk_72 clk_144 2 72 mhz clk_66 clk_133 2 66.46155 mhz clk_62 clk_123 2 61.7143 mhz clk_58 clk_115 2 57.6 mhz clk_54 clk_108 2 54 mhz clk_48 clk_192 4 48 mhz clk_39 clk_157 4 39.272725 mhz clk_33 clk_133 4 33.230775 mhz clk_24 clk_192 8 24 mhz clk_17 clk_133 8 16.6153875 mhz clk_13_5 clk_108 8 13.5 mhz
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-11 2.2.3 the dds clocks the dds clocks are recommended for clocks that need to track dynamically another frequency by very small steps. the following equations characterize the pnx15xx series dds blocks: , where n is a 31-bit value stored in the dds[8:0]_ctl mmio registers (7) (8) (9) 2.2.4 dds and pll assignment summary the figure 6 summarizes the assignment of the different ddses of the pnx15xx series system. 2.2.5 external clocks t ab le 7 lists all the possible external clocks to pnx15xx series. the de?ition of an external clock is any in-coming clock that feeds a pnx15xx series module or any internal pnx15xx series clock that can drive a pnx15xx series i/o pin. f dds 1.728ghz n 2 32 -------------------------------- ---- = jitter 1 1.728ghz ------------------------- 0.579n s == s tep 1.728ghz 2 32 ------------------------- 0.4h z == table 6: dds and pll clock assignment source destinations pll0 clk_tm pll1 clk_fgpo clk_lan clk_qvcp_out ao_osclk pll2 clk_mem dds0/pll0 clk_tm dds1/pll1 clk_fgpo clk_lan clk_qvcp_out ao_osclk dds2 clk_fgpo clk_gpio_14 dds3 ao_osclk dds4 ai_osclk clk_lan dds5 clk_spdo clk_gpio_13 dds6 clk_gpio_q6_12 dds7 clk_vip clk_gpio_q5 clk_lan dds8 clk_gpio_q4 clk_fgpi table 7: external clocks signal name frequency in/out pin i/o name description xtal_clk 27 mhz crystal in xtal_in 27 mhz clock input from oscillator pad clk_pci 33.23 mhz out pci_sys_clk clock to off-chip pci devices; note this signal may be routed back into the pci_clk input pad. clk_pci_i up to 33.33 mhz in pci_clk external pci module clock
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-12 remark: refer to chapter to see series resistors board requirements. mm_clk_out, clk_mem up to 200 mhz out mm_clk mm_clk# ddr sdram clock output clk_vip up to 81 mhz in/out vdi_clk1 vip clock clk_fgpi up to 100 mhz in/out vdi_clk2 fgpi clock clk_qvcp up to 81 mhz in/out vdo_clk1 qvcp clock clk_fgpo up to 100 mhz in/out vdo_clk2 fgpo clock ai_osclk up to 50 mhz out ai_osclk audio input oversampling clock ai_sck up to 25 mhz in/out ai_sck audio input input/output bit clock ao_osclk up to 50 mhz out ao_osclk audio output oversampling clock ao_sck up to 25 mhz in/out ao_sck audio output input/output bit clock clk_lan up to 50 mhz out lan_clk to 10/100 mac phy clock clk_lan_tx up to 27 mhz in lan_tx_clk from 10/100 mac phy transmit clock clk_lan_rx up to 27 mhz in lan_rx_clk from 10/100 mac phy receive clock clk_gpio_4q up to 108 mhz in/out gpio04 gpio sampling/pattern generation clock clk_gpio_5q up to 108 mhz in/out gpio05 gpio sampling/pattern generation clock clk_gpio_6q_12 up to 108 mhz in/out out gpio06 gpio12 gpio sampling/pattern generation clock gpio board level clock clk_gpio_13 up to 108 mhz out gpio13 gpio board level clock clk_gpio_14 up to 108 mhz out gpio14 gpio board level clock table 7: external clocks signal name frequency in/out pin i/o name description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-13 2.3 clock control logic all the generated pnx15xx series clocks follow the generic block diagram presented in figure 3 . the signals in red are for ate purpose and are disabled in normal functional operating mode. the clock module allows several clock sources per clock signal. the different clock sources are selected with a multiplexer. in order to guaranty a glitch free dynamic clock switch a blocking block is added after the clock multiplexer. the same blocking mechanism is necessary when the pll control register is re- programmed since the pll clock needs ?st to be stable, i.e. locks, before it can be used by any module. so the pll clock is ?st blocked by the blocking circuit before the new pll parameters are passed to the pll. the blocking circuit will block the clock output when the turn_off signal is set by the blocking logic. the clock is blocked after a falling edge to ensure the clock is held low. once the blocking circuit has blocked the clock, the turn_off_ack signal is set to high, and it is then safe to pass the new parameters to the pll. figure 3: block diagram of the clock control logic /n blocking ext_clk clock_out blocking logic re-program pll parameters or exit_reset reg is set clock control logic slice cab ?econd_clk or testmode switch mux if: logic re-program clock divider clk_in turn_off turn_off _ack turn_off turn_off _ack clk_out 1.728 ghz pll divider n = 2,3,4,5,6 tst_clk_sel tst_clk_x xtal_clk tst_cab_bypass slice_tst_in slice_tst_ou t
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-14 the blocking will be released after a safe interval of 300 s. the 300 s is counted using the 27 mhz xtal_clk. figure 4 illustrates the sequence of events. the second blocking lasts for less than 10 xtal_clk cycles since it assumes the clocks are stable. remark: that 2 blocking circuits are used so that xtal_clk may continue being output uninterrupted while the pll is being re-programmed clocks are also switched if: the system has come out of reset and boot-up sequence a clock needs to be stretched or stopped for dfd ( section 2.6 ) 2.4 bypass clock sources in the event of any issue with the clock sources from the cab, it is possible to switch these clocks to off-chip sources. these external clock sources will be routed through the gpio pins as summarized in t ab le 8 . this mode is not meant to be a functional operating mode but just a help for bringup systems based on pnx15xx series. figure 4: waveforms of the blocking logic turn_off clk_pll clk_out turn_off_ack clk_out is blocked when safe to re-program clk_pll turn_off_ack=1. it is now then release turn_off clk_out blocked xtal_clk 300us table 8: bypass clock sources clocks from clock module bypass control register gpio pin assignment clk_tm clk_tm_ctl ai_ws clk_mem clk_mem_ctl gpio[7] clk_2dde clk_2dde_ctl ai_sd[1] clk_pci clk_pci_ctl ai_sd[2] clk_mbs clk_mbs_ctl ai_sd[3] clk_tstamp clk_tstamp_ctl ao_ws clk_lan clk_lan_ctl ao_sd[0] clk_iic clk_iic_ctl ao_sd[1] clk_dvdd clk_dvdd_ctl ao_sd[2] clk_dtl_mmio clk_dtl_mmio_ctl ao_sd[3]
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-15 2.5 power-up and reset sequence on power-up, the clock module outputs the default 27 mhz clocks to all the pnx15xx series modules. once the reset module has released the internal module resets, the boot-up sequence executed by the boot module starts off the 27 mhz clock. at some point in the boot up sequence, the boot module switches tm3260 and the ddr clocks to the associated plls, pll0 and pll2. the clock module keeps feeding the other pnx15xx series modules with the initial 27 mhz clock until the software decides otherwise. 2.6 clock stretching the tm3260 clock, clk_tm, can be paused or stretched for one clock pulse. a counter counts to a pre-programmed value. when this value is reached the clock gating circuit will turn off the tm3260 clock for one clock period. then the tm3260 clock is turned back on. the procedure to operate the clock stretching circuit is to program the clk_stretcher_ctl mmio register to the value desired between clock stretches. for example a value of 3 turns off the clock every 3 clocks as pictured in figure 5 . a write to the clk_stretcher_ctl register acts as the enable for the feature. clk_qvcp clk_qvcp_out_ctl xio_ack clk_qvcp_pix clk_qvcp_pix_ctl xio_d[8] clk_qvcp_proc clk_qvcp_proc_ctl xio_d[9] clk_lcd_tstamp clk_lcd_tstamp_ctl xio_d[10] clk_vip clk_vip_ctl xio_d[11] clk_vld clk_vld_ctl xio_d[12] ai_osclk ai_osclk_ctl xio_d[13] ao_osclk ao_osclk_ctl xio_d[14] clk_spdo clk_spdo_ctl xio_d[15] clk_spdi clk_spdi_ctl lan_txd[0] clk_gpio_q4 clk_gpio_q4_ctl lan_txd[1] clk_gpio_q5 clk_gpio_q5_ctl lan_txd[2] clk_gpio_q6_12 clk_gpio_q6_12_ctl lan_txd[3] clk_gpio_13 clk_gpio_13_ctl lan_rxd[0] clk_gpio_14 clk_gpio_14_ctl lan_rxd[1] clk_fgpo clk_fgpo_ctl lan_rxd[2] clk_fgpi clk_fgpi_ctl lan_rxd[3] table 8: bypass clock sources clocks from clock module bypass control register gpio pin assignment
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-16 a write with a 0 value stops the clock stretching circuit. 2.7 clock frequency determination this feature allows the measuring of the internal plls and ddss. this is used for basic test mode only. the enable bits of the clk_freq_ctl choose which of the 12 clocks to test (pll0 - pll2, dds2 - dds8). the count bits choose a count that is based on the xtal clock. while the counting proceeds another counter counts the number of clocks of the chosen clock. when the xtal count ends the done bit in the clk_freq_ctl will be set. at this point the clk_count_results register can be read. knowing the pre-programmed value of xtal clocks and the number of clocks of the chosen clock then the frequency of the chosen clock can be determined. example: program the clk_freq_ctl register for a count of 0x7f. the clk_count_results register is read after seeing the done bit in the clk_freq_ctl set. the value is 0x24b. if xtal is 27 mhz (37ns) then the total period of count time is so 0x24b clocks were counted in 4699 ns. therefore the period of the measured clock is: which is approximately 125 mhz. a simpler formula is: where: countresult is the value read from the clk_count_results register, programmed is the value programmed in the clk_freq_ctl register and xtalperiod is the period in ns of the input crystal clock. figure 5: clock stretcher turn_off stretcher count clk_out turn_off_ack clk_out blocked clk_tm 3 3 0 2 1 0 3 2 clk_out blocked 0x7f 37 4699ns = 4699 0 x24b - --------------- - 8.01n s = f requency countresult xtalperiod programme d ------------------------------------------------------------------ --- =
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-17 2.8 power down all clocks generated in the clock module may be disabled by programming the relevant clock enable bit of each clock control register. it is possible to gate module clocks in individual modules rather than in the clock module. the advantages of centralizing the clock gating are summarized in t ab le 9 . to power down all the clocks including the mmio clock software running on tm3260 must follow this simple procedure. 1. power down all the clocks with the exception of the tm3260 cpu clock, clk_tm, and the mmio clock. accomplish this by writing a zero to bit 0 of each of the clock control registers. before doing so, proper care has to be taken to ensure that the relevant modules have been disabled. 2. write to the clk_tm_ctl mmio register with a value of 0x00000008. this will ?st turn off the tm3260 clock and later the mmio clock. remark: the mmio clock needs to be turned off last but the command needs to come from the tm3260 so they both need to be turned off together. more details on the pnx15xx series powerdown can be found in the chapter 27 p o w er management . 2.8.1 wake-up from power down there are three ways to wake up the pnx15xx series when the mmio clock is turned off 1) wake-up timer 2) gpio interrupt 3) external wake-up signal on gpio[15] the wake-up timer is in the clock block and is controlled by the clk_wakeup_ctl. the wake-up timer is enabled when any value except 0 is written to it. after a value is written to this register the timer starts counting xtal clocks (27 mhz) until the value programmed in the register is reached. once the value is reached both the mmio and the tm3260 clocks are re-activated to 27 mhz. table 9: advantages of centralized clock gating control clock gating in module clock gating in clock module comments logic & s/w point of view + - more logical for s/w to write to module regs to switch off module_clks history (existing modules) - + existing modules and ip modules are usually not delivered with clock gating implemented risk - + clock control is safer being centralized, rather than scattered in every module switching of plls/debug mode - + clocks are already blocked in the clock module during re-programming of plls and dividers or during debug mode.
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-18 the gpio interrupt comes from the gpio block and is the ?r?of all the fifo and timestamp registers. this way a gpio pin can be monitored and when an event occurs the interrupt to the processor awakes the system. bit ??of the clk_wakeup_ctl enables the gpio interrupt. the external signal is the dedicated gpio pin 15. this signal must be active for at least one xtal_clk clock period. it is expected that this signal will stay active until the cpu responds which will be several xtal clock periods. bit ??of the clk_wakeup_ctl enables the external interrupt. gpio[15] must be low when entering in power down mode since the wake-up procedure is started when the gpio[15] pin is set to high for at least one xtal_clk clock cycle. 2.9 clock detection clock detection is required in the case of an external clock being removed or disconnected e.g if the video cable to the set top box is suddenly removed and an external video clock thereby stopped. this type of event is detected by the clock module. also the clock module can detect when the cable is re-connected and a clock is present again. these events are ?gged by an interrupt which is routed to the tm3260. the clock detection will be done on the following clocks inputs to pnx15xx series: vdi_clk1 (clk_vip) ai_sck ao_sck vdi_clk2 (clk_fgpi) vdo_clk2 (clk_fgpo) clock detection is done based on a 5-bit counter running at the crystal clock frequency. the implementation detects clocks between 1 mhz and 200 mhz. it will take up to 2 s from when the clock is removed until the interrupt condition is generated. a block diagram of the clock detection circuit is shown in figure 6 . figure 6: clock detection circuit (external clock) xtal_clk counter xtal_clk xtal_clk comp 32 en edge detect clock_present pls2lvl pio int intrpt_clk toggle flop en
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-19 an interrupt is generated whenever the signal 'clock present' changes status. therefore an interrupt is generated if a clock changes from 'present' to 'non-present or from 'non-present to 'present'. the interrupt registers are implemented using the standard peripheral interrupt module and can thus be enabled/cleared/set by software. in the pnx15xx series all of the above clocks can also be generated internally. in this case the clock detection circuit can still be enabled. if the internal source is changed then the clock detection circuit will detect the period of time that there is not a clock. at this time the logic updates the interrupt status register and asserts an interrupt if the interrupt is enabled. the interrupts are by default disabled and should remain that way as long as the clock is generated internally. if in the course of time the output clock is changed to an input the interrupt status register needs to be cleared before the interrupts are enabled. 2.10 vdo clocks the two vdo out clocks, vdo_clk1 and vdo_clk2, have several operating modes. a brief explanation of these modes is included in this section. each clock has three possible modes, input, separate output, and feedback mode. in input mode an external clock is driving these clocks (hence driving qvcp/lcd and fgpo). in separate output mode the clock module drives both the clocks going to the ip (qvcp/ lcd and fgpo) and to its related output clock vdo_clk1 and vdo_clk2. in this case the source of the clock is the same, but the paths are totally separate. the third mode is feedback mode. in feedback mode the clock module drives the output clock, vdo_clk1 and vdo_clk2. this clock is then feedback through the pad to the clock module. then it goes on to the ip (qvcp/lcd and fgpo). diagrams of these clocks can be found in figure 17 on page 5- 28 and figure 18 on page 5- 28 . to select between output and input mode a bit is provided in each of the con?uration registers for qvcp and fgpo. writing to the qvcp_output_enable bit will change the direction of the qvcp clock. writing to the fgpo_output_enable bit will change the direction of the fgpo clock. the output mode (separate or feedback) for the qvcp is selected by the qvcp_output_select bit. the fgpo_output_select bit selects the mode (separate or feedback) for the fgpo clock. both vdo clocks can also be programmed to have an inverted clock. there are two possible ways to invert the clock. if the invert clock bit is set then the inverted clock goes to the ip and the non inverted clock goes to the clock outputs. the qvcp clock is inverted by setting the invert_qvcp_clock bit in the qvcp con?uration register. the fgpo clock is inverted by setting the invert_fgpo_clock bit in the fgpo con?uration register. also in output mode the qvcp source clock can be inverted by setting the sel_clk_qvcp bit to ?0? the fgpo source clock can also be inverted by setting the sel_clk_fgpo bit to ?0? by doing this the clock is inverted to both the internal and external version of the clock. in input mode the clock coming into the chip is inverted before being sent to the ip. in qvcp this is done by again writing to the invert_qvcp_clock bit. in fgpo the invert_fgpo_clock bit can also be set to invert the clock to the ip. in input mode the sel_clk_qvcp does not get used. for both clocks they come out of reset in a quasi-input/output mode. the pad is set to be an input and the ip is being driven by the crystal clock (xtal_in) and not the input clock (if any). this is to allow the ip to reset if there isn? an input clock as well as
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-20 protecting an input clock from contention by having the pad set to an input (in the case of an input clock). in both cases a write to each control register is necessary to properly put the clock into an input or output con?uration (otherwise the logic will remain in the quasi-input/output mode). as indicated above vdo_clk1 can either be qvcp or lcd. after reset the clocks are in the above mentioned quasi-input/output mode. if it is to be lcd then the qvcp_out control register must be programmed to ?eparate output mode. if the lcd only bit (bit 31 in the lcd_setup mmio register) is set then the output select bit in the qvcp_out control register cannot be written to a ??(feedback mode). the lcd mode register can only be written to once and then only to disable lcd mode. if this is done then the output select bit can be programmed to any value. 2.11 gpio clocks the folowing sections present the sequence of actions required to enable clocks on the gpio[12:14,6:4?pins. 2.11.1 setting gpio[14:12]/gclock[2:0] as clock outputs set gpio pin to gpio mode 2 using gpio_mode_0_15 ( t ab le 7 on page 8- 24 ) set gpio pin to output a 0 using gpio_mask_iod_0_15 ( t ab le 8 on page 8- 26 ) set dds frequency using ddsx_ctl ( t ab le 11 on page 5- 34 ) enable dds output to clk_gpio_y using clk_gpio_y_ctl ( t ab le 11 on page 5- 34 ) enable clk_gpio_y to pin using dds_out_sel ( t ab le 16 on page 8- 36 ) 2.11.2 gpio[6:4]/clock[6:4] as clock outputs set gpio pin to gpio mode 2 using gpio_mode_0_15 ( t ab le 7 on page 8- 24 ) set gpio pin to output a 0 using gpio_mask_iod_0_15 ( t ab le 8 on page 8- 26 ) set dds frequency using ddsx_ctl ( t ab le 11 on page 5- 34 ) enable dds output to clk_gpio_y using clk_gpio_y_ctl ( t ab le 11 on page 5- 34 )gpio_ev_x. set gpio_ev_x.en_dds_source = 1 and gpio_ev_x.clock_sel = 4 for gpio[4], 5 for gpio[5] and 6 for gpio[6] ( t ab le 10 on page 8- 27 ) 2.12 clock block diagrams the following sections present the block diagrams of the different clocks generated by the clock module.
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-21 2.12.1 tm3260, ddr and qvcp clocks figure 7: tm3260, ddr and qvcp clocks pll2 cab n,m, current_adj blocking blocking gpio parameters clock pll1 blocking clk_qvcp blocking n,m,p parameters tst_clk_mem tst_clk_qvcp_out slice_tst_in slice_tst_in slice_tst_out gpio xtal_clk pll2 is located outside cab clk_mem_ou t slice_tst_out cab blocking clk_tm blocking tst_clk_tm slice_tst_in slice_tst_out gpio pll0 n,m,p parameters undef ddsn control parameters dds0 dds1 duty cycle 75/25 note: see figure 17 for more information on the qvcp_out pll1 27 mhz 27 mhz
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-22 clk_qvcp_out generation is presented in figure 17 . it is important to notice that the clock used for clk_qvcp_out can be the inverted version of the clock present in the vdo_clk1 pin. this allows the qvcp block to output data on the falling edge instead of the default positive edge. this feature may also be used to translate the ac timing characteristics that are computed with respect to the vdo_clk1 positive edge. figure 8: qvcp_proc clock figure 9: qvcp_pix clock clk_qvcp_proc tst_clk_qvcp_proc xtal_clk blocking sel_qvcp_proc_clk_src sel_qvcp_proc_clk clk_17 clk_33 clk_39 clk_58 clk_78 clk_86 clk_96 clk_108 clk_133 clk_144 slice_tst_out gpio slice_tst_out blocking tst_clk_qvcp_pix sel_clk_qvcp_pix clk_qvcp_pix clk_qvcp_out /1 /2 /3 /4 /6 /8 div_clk_qvcp_pix gpio xtal_clk
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-23 2.12.2 clock dividers figure 10: clock dividers 1.728 ghz pll / / / / / / / / clk_192 clk_123 clk_173 clk_144 clk_157 clk_115 clk_108 clk_133 cab clocks block clk_192 clk_123 clk_96 clk_144 clk_115 clk_108 clk_133 / / / / / clk_173 clk_86 clk_72 clk_62 clk_54 slice_tst_in / clk_58 / clk_102 clk_102 clk_48 clk_24 clk_78 / clk_157 clk_39 / clk_66 clk_33 clk_17
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-24 2.12.3 internal pnx15xx series clock from dividers figure 11: internal pnx15xx series clock from dividers clk_mbs clk_dvdd clk_dtl_mmio clk_vld clk_2dde blocking tst_clk_2dde clk_66 clk_72 clk_78 clk_86 clk_96 clk_108 clk_123 clk_144 sel_2dde_clk_src xtal_clk blocking blocking blocking blocking clk_66 clk_72 clk_78 clk_86 clk_96 clk_108 clk_123 clk_144 clk_54 clk_72 clk_78 clk_86 clk_96 clk_108 clk_123 clk_144 clk_54 clk_102 clk_108 clk_115 clk_123 clk_133 clk_144 clk_157 clk_66 clk_72 clk_78 clk_86 clk_96 clk_108 clk_133 clk_144 sel_clk_mbs_src sel_dvdd_clk_src sel_dtl_mmio_clk_src sel_vld_clk_src sel_2dde_clk sel_mbs_clk sel_dvdd_clk sel_dtl_mmio_clk sel_vld_clk tst_clk_mbs tst_clk_dvdd tst_clk_dtl_mmio tst_clk_vld slice_tst_out slice_tst_out slice_tst_out slice_tst_out slice_tst_out gpio
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-25 figure 12: internal pnx15xx series clock from dividers: pci, spdi, lcd and i 2 c clk_spdi clk_tstamp clk_pci blocking tst_clk_pci xtal_clk blocking blocking clk_72 clk_33 clk_144 clk_108 clk_iic blocking clk_48 sel_iic_clk sel_tstamp_clk sel_spdi_clk sel_pci_clk /2 clk_13_5 undef tst_clk_spdi tst_clk_tstamp tst_clk_iic slice_tst_out slice_tst_out slice_tst_out slice_tst_out xtal_clk/16 gpio figure 13: internal pnx15xx series clock from dividers: lcd timestamp tst_clk_lcd_tstamp gpio xtal_clk blocking clk_lcd_tstamp sel_lcd_tstamp_clk slice_tst_out
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-26 2.12.4 gpio clocks figure 14: gpio clocks blocking xtal_clk dds8 clock module tst_clk_gpio_q4 tst_clk_a slice_tst_out clk_gpio_q4 blocking xtal_clk dds7 clock module tst_clk_gpio_q5 tst_clk_a slice_tst_out clk_gpio_q5 blocking xtal_clk dds6 clock module tst_clk_gpio_q6 tst_clk_a slice_tst_out clk_gpio_q6_12 blocking xtal_clk dds5 clock module tst_clk_gpio_13 tst_clk_a slice_tst_out clk_gpio_13 undef blocking xtal_clk dds2 clock module tst_clk_gpio_14 tst_clk_a slice_tst_out clk_gpio_14 undef gpio gpio gpio gpio gpio sel_clk_gpio_13_ctl sel_clk_gpio_14_ctl sel_clk_gpio_q6_12_ctl sel_clk_gpio_q5_ctl sel_clk_gpio_q4_ctl
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-27 2.12.5 external clocks figure 15: vdi_clk1 block diagram blocking xtal_clk clock module tst_clk_vip clk_vip slice_tst_out vdi_clk1 blocking xtal_clk dds7 gpio sel_clk_vip vip_output_enable_n sel_clk_vip/reset figure 16: vdi_clk2 block diagram blocking xtal_clk clock module tst_clk_fgpi clk_fgpi slice_tst_out vdi_clk2 blocking xtal_clk dds8 gpio sel_clk_fgpi fgpi_output_enable_n dds3 sel_clk_fgpi/reset sel_clk_fgpi_src
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-28 figure 17: vdo_clk1 block diagram blocking xtal_clk clock module tst_clk_qvcp clk_qvcp_out slice_tst_out vdo_clk1 blocking gpio sel_clk_qvcp qvcp_output_enable_n pll1 output router clk_qvcp qvcp_output_enable_n qvcp_output_select invert_clk_qvcp clk_lcd note: lcd clock path clk_tft note: derived from the clk_lcd figure 18: vdo_clk2 block diagram blocking xtal_clk clock module tst_clk_fgpo clk_fgpo slice_tst_out vdo_clk2 blocking gpio sel_clk_fgpo fgpo_output_enable_n pll1 output router undef dds2 sel_clk_fgpo_src fgpo_output_enable_n fgpo_output_select invert_clk_fgpo
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-29 figure 19: ao clocks xtal_clk clock module blocking slice_tst_clk audio output module tst_clk_a ao_osclk_ctl ao_sck blocking xtal_clk tst_clk tps_ao_sck_oen tps_ao_sckout slice_tst_out clk_ao_sck_o dds3 gpio ? ao_osclk pll1 slice_tst_out ao_sck_ctl figure 20: ai clocks xtal_clk clock module blocking audio input module tst_clk_a ai_sck blocking xtal_clk tst_clk tps_ai_sck_oen tps_ai_sckout slice_tst_out clk_ai_sck_o dds4 gpio ? ai_osclk slice_tst_out ai_osclk_ctl slice_tst_clk ai_sck_ctl
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-30 figure 21: phy lan clock block diagram xtal_clk blocking tst_clk_lan slice_tst_clk sel_clk_lan undef gpio ? clk_lan slice_tst_out pll1 dds4 dds7 sel_clk_lan_clk_src figure 22: receive and transmit lan clocks clk_lan_r/tx xtal_clk blocking tst_clk_lan sel_clk_lan slice_tst_out clk_lan_r/tx slice_tst_clk
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-31 2.12.6 spdo 3. registers de?ition 3.1 registers summary figure 23: spdo clock table 10: registers summar offset name description 0x04,7000 pll0_ctl pll0 control register 0x04,7004 pll1_ctl pll1 control register 0x04,7008 pll2_ctl pll2 control register 0x04,700c pll1_7_ctl pll 1.728 ghz control register 0x04,7010 dds0_ctl dds0: frequency control 0x04,7014 dds1_ctl dds1: frequency control 0x04,718 dds2_ctl dds2: frequency control 0x04,701c dds3_ctl dds3: frequency control 0x04,7020 dds4_ctl dds4: frequency control 0x04,7024 dds5_ctl dds5: frequency control 0x04,7028 dds6_ctl dds6: frequency control 0x04,702c dds7_ctl dds7: frequency control 0x04,7030 dds8_ctl dds8: frequency control 0x04,7034 cab_div_pd cab clocks divider powerdown signals 0x04,7038- 0x04,70fc reserved reserved 0x04,7100 clk_tm_ctl tm3260 clock control 0x04,7104 clk_mem_ctl ddr memory clock control 0x04,7108 clk_2d2_ctl 2d drawing engine clock control 0x04,710c clk_pci_ctl pci clock control 0x04,7110 clk_mbs_ctl mbs clock control 0x04,7114 clk_tstamp_ctl time stamp clock control 0x04,7118 clk_lan_ctl ethernet clock control 0x04,711c clk_lan_rx_ctl ethernet rx clock control 0x04,7120 clk_lan_tx_ctl ethernet tx clock control xtal_clk clk_spdo blocking tst_clk slice_tst_out sel_clk_spdo dds5 gpio
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-32 0x04,7124 clk_iic_ctl i 2 c clock control 0x04,7128 clk_dvdd_ctl dvdd clock control 0x04,712c clk_mmio_ctl mmio clock control, a.k.a. dcs clock 0x04,7130- 0x04,71fc reserved reserved 0x04,7200 clk_qvcp_out_ctl qvcp clock output control 0x04,7204 clk_qvcp_pix_ctl qvcp pix clock control 0x04,7208 clk_qvcp_proc_ctl qvcp proc clock control 0x04,720c clk_lcd_tstamp_ctl lcd timestamp clock control 0x04,7210 clk_vip_ctl video input processor clock control 0x04,7214 clk_vld_ctl vld clock control 0x04,7218- 0x04,72fc reserved reserved 0x04,7300 ai_osclk_ctl audio in over sampling clock control 0x04,7304 ai_sck_ctl audio in sampling clock control 0x04,7308 ao_osclk_ctl audio out over sampling clock control 0x04,730c ao_sck_ctl audio out sampling clock control 0x04,7310 clk_spdo_ctl spdo clock control 0x04,7314 clk_spdi_ctl spdi clock control 0x04,7318- 0x04,73fc reserved reserved 0x04,7400 gpio_clk_q4_ctl gpio clock to fifo and pin 4 control 0x04,7404 gpio_clk_q5_ctl gpio clock to fifo and pin 5 control 0x04,7408 gpio_clk_q6_12_ctl gpio clock to fifo and pin 6/12 control 0x04,740c gpio_clk_13_ctl gpio clock to pin 13 0x04,7410 gpio_clk_14_ctl gpio clock to pin 14 0x04,7414 clk_fgpo_ctl fgpo clock control 0x04,7418 clk_fgpi_ctl fgpi clock control 0x04,741c- 0x04,74fc reserved reserved 0x04,7500 clk_stretcher_ctl clock stretcher count register 0x04,7504 clk_wakeup_ctl wake-up count register 0x04,7508 clk_freq_ctl pll/dds frequency count register 0x04,750c clk_result_ctl pll/dds frequency count result register 0x04,7510 aligner_adjust reserved 0x04,7514- 0x04,7fdc reserved reserved 0x04,7fe0 interrupt_status status of clock detection interrupts 0x04,7fe4 interrupt_enable enable clock detection interrupts 0x04,7fe8 interrupt_clear clear clock detection interrupts table 10: registers summar offset name description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-33 0x04,7fec interrupt_set set clock detection interrupts 0x04,7ff0- 0x04,7ff8 reserved reserved 0x04,7ffc module_id module identi?ation and revision information table 10: registers summar offset name description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-34 3.2 registers description table 11: clock module registers bit symbol acces s value description pll registers offset 0x04,7000 pll0_ctl reset values set for expected frequencies for faster boot-up, shorter boot code. 31:30 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 29 turn off acknowledge r - indicates that during a frequency change that the clock has been driven low. 28 pll lock r - a ??indicates that the pll is locked 27:24 pll0_adj r/w 0 current adjustment. section 2.2.1 on page 5- 8 . 23:21 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 20:12 pll0_n r/w 0x4a 9-bit n parameter to pll0 11:10 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 9:4 pll0_m r/w 0x5 6-bit m parameter to pll0. section 2.2.1 on page 5- 8 . 3:2 pll0_p r/w 0 2-bit p parameter to pll0. section 2.2.1 on page 5- 8 . 1 pll0_pd r/w 0 1: powerdown pll0 0 pll0_bp r/w 1 0: do not bypass the dds 1: bypass the dds and use the xtal (27 mhz). normal operating mode. offset 0x04,7004 pll1_ctl reset values set for expected frequencies for faster boot-up, shorter boot code. 31:30 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 29 turn off acknowledge r - indicates that during a frequency change that the clock has been driven low. 28 pll lock r - a ??indicates that the pll is locked 27:24 pll1_adj r/w 4 current adjustment. section 2.2.1 on page 5- 8 . 23:21 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 20:12 pll1_n r/w 0x22 9-bit n parameter to pll1. section 2.2.1 on page 5- 8 . 11:10 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 9:4 pll1_m r/w 6 6-bit m parameter to pll1. section 2.2.1 on page 5- 8 . 3:2 pll1_p r/w 2 2-bit p parameter to pll1. section 2.2.1 on page 5- 8 . 1 pll1_pd r/w 0 1: powerdown pll1 0 pll1_bp r/w 1 0: do not bypass the dds. 1: bypass the dds and use the xtal (27 mhz)
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-35 offset 0x04,7008 pll2_ctl reset values set for expected frequencies for faster boot-up, shorter boot code. 31:30 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 29 turn off acknowledge r - indicates that during a frequency change that the clock has been driven low. 28 pll lock r - a one indicates that the pll is locked 27:24 pll2_adj r/w 0 current adjustment. section 2.2.1 on page 5- 8 . 23:21 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 20:12 pll2_n r/w 0x2e 9-bit n parameter to pll2. section 2.2.1 on page 5- 8 . 11:10 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 9:4 pll2_m r/w 0x5 6-bit m parameter to pll2. section 2.2.1 on page 5- 8 . 3:2 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 1 pll2_pd r/w 0 1: powerdown pll2 0 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. offset 0x04,700c pll1_7ghz_ctl 31:3 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 2 pll1_7ghz_pd r/w 0 1: powerdown pll1_7ghz 1:0 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. dds registers offset 0x04,7010 dds0_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds0_ctl[30 :0] r/w 0x07684 bd0 31-bit dds0 control (default = 50 mhz) offset 0x04,7014 dds1_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds1_ctl[30:0] r/w 0x04000 000 31-bit dds1 control (default = 27 mhz) offset 0x04,7018 dds2_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds2_ctl[30:0] r/w 0x04000 000 31-bit dds2 control (default = 27 mhz) table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-36 offset 0x04,701c dds3_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds3_ctl[30:0] r/w 0x02f68 4c0 31-bit dds3 control (default = 20 mhz) offset 0x04,7020 dd4_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds4_ctl[30:0] r/w 0x02f68 4c0 31-bit dds4 control (default = 20 mhz) offset 0x04,7024 dds5_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds5_ctl[30:0] r/w 0x00e90 452 31-bit dds5 control (default = 128*48khz = 6.14 mhz) offset 0x04,7028 dds6_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds6_ctl[30:0] r/w 0x04000 000 31-bit dds6 control (default = 27 mhz) offset 0x04,702c dds7_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds7_ctl[30:0] r/w 0x04000 000 31-bit dds7 control (default = 27 mhz) offset 0x04,7030 dds8_ctl 31 enable r/w 0 1: enables the dds. the input of the dds is then the 1.7ghz clock. 0: test mode. do not use. 30:0 dds8_ctl[30:0] r/w 0x04000 000 31-bit dds8 control (default = 27 mhz) divider registers: for register 34h power down appropriate clocks before setting these bits offset 0x04,7034 cab_divider_ctl 31:8 reserved r/w to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 8 pd_192 r/w 0 power down 192 mhz divider in the cab block. 7 pd_173 r/w 0 power down 173 mhz divider in the cab block. 6 pd_157 r/w 0 power down 157 mhz divider in the cab block. 5 pd_144 r/w 0 power down 144 mhz divider in the cab block. 4 pd_133 r/w 0 power down 133 mhz divider in the cab block. 3 pd_123 r/w 0 power down 123 mhz divider in the cab block. 2 pd_115 r/w 0 power down 115 mhz divider in the cab block. table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-37 1 pd_108 r/w 0 power down 108 mhz divider in the cab block. 0 pd_102 r/w 0 power down 102 mhz divider in the cab block. offset 0x04,7038-0x04,70fcreserved module clocks offset 0x04,7100 clk_tm_ctl 31:6 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 5 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 4 tm_stretch_n r/w 0 0 - turns on the 75/25 duty cycle adjust circuit 1 - turns off the 75/25 duty cycle adjust circuit must be set to ??for normal operation. 3 sel_pwrdwn_clk_mmio w 0 this bit allows the tm3260 to turn off the mmio clock simultaneously with the tm3260 clock. this mechanism allows to go into deep sleep mode and allows to keep the capability to wake- up from this deep sleep mode ( section 2.8.1 on page 5- 17 ). when deep sleep mode is requested by tm3260, it must turn off its own clock, clk_tm, by setting en_clk_tm to ??and sel_pwrdwn_clk_mmio to ?? writing to a ??to en_clk_tm without setting sel_pwrdwn_clk_mmio to ??shuts down tm3260 clock forever (unless a host writes back a ??to ?n_clk_tm?or a system reset occurs). therefore, the only use of sel_pwrdwn_clk_mmio is to set it to ? at the same time en_clk_tm is set to ?? the tm3260 must run a waiting loop of 10 27 mhz cycles after the write to clk_tm_ctl is done since the clk_tm is not immediately turned off. upon wake-up, en_clk_tm and sel_pwrdwn_clk_mmio get their initial reset value and tm3260 resumes from where it stopped. maximum power saving is achieved by turning off the pll0 and therefore switch to the 27 mhz xtal_clk clock before requesting a deep sleep mode. similarly the other clocks of the system must be turned off separately if maximum power saving needs to be achieved. this may include the ddr clock. upon wake-up, if a pll has been turned off, a minimum of 100 sis required to lock it. 2:1 sel_clk_tm r/w 0 00: clk_tm = 27 mhz xtal_clk 01: clk_tm = tm_stretch_n (output of the duty cycle stretcher) 10: clk_tm = undef 11: clk_tm = ai_ws 0 en_clk_tm r/w 1 1: enable clk_tm offset 0x04,7104 clk_mem_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-38 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_mem r/w 00 00: clk_mem = pll2 01: clk_mem = pll2 10: clk_mem = 27 mhz xtal_clk 11: clk_mem = gpio[7] 0 en_clk_mem r/w 1 1: enable clk_mem offset 0x04,7108 clk_2dde_ctl 31:7 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 5:3 sel_clk_2dde_src r/w 111 000: clk_2dde_src = clk_144 001: clk_2dde_src = clk_123 010: clk_2dde_src = clk_108 011: clk_2dde_src = clk_96 100: clk_2dde_src = clk_86 101: clk_2dde_src = clk_78 110: clk_2dde_src = clk_72 111: clk_2dde_src = clk_66 2:1 sel_clk_2dde r/w 00 00: clk_2dde = 27 mhz xtal_clk 01: clk_2dde = clk_2d2_src 10: clk_2dde = 27 mhz xtal_clk 11: clk_2dde = ai_sd[1] 0 en_clk_2dde r/w 1 1: enable clk_2dde offset 0x04,710c clk_pci_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_pci r/w 01 00: clk_pci = 27 mhz xtal_clk 01: clk_pci = clk_33 10: clk_pci = xtal_clk/16 = 1.68 mhz 11: clk_pci = ai_sd[2] 0 en_clk_pci r/w 1 1: enable clk_pci offset 0x04,7110 clk_mbs_ctl 31:7 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-39 6 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 5:3 sel_clk_mbs_src r/w 111 000: clk_mbs_src = clk_144 001: clk_mbs_src = clk_123 010: clk_mbs_src = clk_108 011: clk_mbs_src = clk_96 100: clk_mbs_src = clk_86 101: clk_mbs_src = clk_78 110: clk_mbs_src = clk_72 111: clk_mbs_src = clk_66 2:1 sel_clk_mbs r/w 00 00: clk_mbs = 27 mhz xtal_clk 01: clk_mbs = clk_mbs_src 10: clk_mbs = 27 mhz xtal_clk 11: clk_mbs = ai_sd[3] 0 en_clk_mbs r/w 1 1: enable clk_mbs offset 0x04,7114 clk_tstamp_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_tstamp r/w 00 00: clk_tstamp = 27 mhz xtal_clk 01: clk_tstamp = source clock (clk_108) 10: clk_tstamp = second clock (clk_13_5) 11: clk_tstamp = ao_ws 0 en_clk_tstamp r/w 1 1: enable clk_tstamp offset 0x04,7118 clk_lan_ctl 31:6 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 5 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 4:3 sel_lan_clk_src r/w 00 00: clk_lan_src = undef 01: clk_lan_src = pll1 10: clk_lan_src = dds4 11: clk_lan_src = dds7 table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-40 2:1 sel_clk_lan r/w 00 00: clk_lan = 27 mhz xtal_clk 01: clk_lan = clk_lan_src 10: clk_lan = 27 mhz xtal_clk 11: clk_lan = ao_sd[0] 0 en_clk_lan r/w 1 1: enable clk_lan offset 0x04,711c clk_lan_rx_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_lan_rx r/w 00 00: clk_lan_rx = 27 mhz xtal_clk 01: clk_lan_rx = clk_lan_rx pin 10: clk_lan_rx = 27 mhz xtal_clk 11: clk_lan_rx = clk_lan_rx pin 0 en_clk_lan_rx r/w 1 1: enable clk_lan_rx offset 0x04,7120 clk_lan_tx_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_lan_tx r/w 00 00: clk_lan_tx = 27 mhz xtal_clk 01: clk_lan_tx = clk_lan_tx pin 10: clk_lan_tx = 27 mhz xtal_clk) 11: clk_lan_tx = clk_lan_tx pin 0 en_clk_lan_tx r/w 1 1: enable clk_lan_tx offset 0x04,7124 clk_iic_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_iic r/w 00 00: clk_iic_tx = 27 mhz xtal_clk 01: clk_iic_tx = clk_24 10: clk_iic_tx = 27 mhz xtal_clk 11: clk_iic_tx = ao_sd[1] 0 en_clk_iic r/w 1 1: enable clk_iic offset 0x04,7128 clk_dvdd_ctl 31:7 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-41 6 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 5:3 sel_clk_dvdd_src r/w 111 000: clk_dvdd_src = clk_144 001: clk_dvdd_src = clk_123 010: clk_dvdd_src = clk_108 011: clk_dvdd_src = clk_96 100: clk_dvdd_src = clk_86 101: clk_dvdd_src = clk_78 110: clk_dvdd_src = clk_72 111: clk_dvdd_src = clk_54 2:1 sel_clk_dvdd r/w 00 00: clk_dvdd = 27 mhz xtal_clk 01: clk_dvdd = clk_dvdd_src 10: clk_dvdd = 27 mhz xtal_clk 11: clk_dvdd = ao_sd[2] 0 en_clk_dvdd r/w 1 1: enable clk_dvdd offset 0x04,712c clk_dtl_mmio_ctl 31:7 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 5:3 sel_clk_dtl_mmio_src r/w 000 000: clk_dtl_mmio_src = clk_102 001: clk_dtl_mmio_src = clk_108 010: clk_dtl_mmio_src = clk_115 011: clk_dtl_mmio_src = clk_123 100: clk_dtl_mmio_src = clk_133 101: clk_dtl_mmio_src = clk_144 110: clk_dtl_mmio_src = clk_157 111: clk_dtl_mmio_src = clk_54 2:1 sel_clk_dtl_mmio r/w 00 00: clk_dtl_mmio = 27 mhz xtal_clk 01: clk_dtl_mmio = clk_dtl_mmio_src 10: clk_dtl_mmio = 27 mhz xtal_clk 11: clk_dtl_mmio = ao_sd[3] 0 en_dtl_mmio r/w 1 1: enable clk_dtl_mmio offset 0x04,7200 clk_qvcp_out_ctl 31:7 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-42 5 invert_qvcp_clock r/w 0 invert qvcp clock 0 : do not invert the clock 1: invert the clock only to the qvcp block and not to the pad. 4 qvcp_output_select r/w 0 qvcp output select 0: seperate output mode, the clock to the qvcp and to the pad share the same source, but have seperate paths. this mode is also the lcd only mode (see qvcp/lcd description). if the lcd only bit is set then this bit cannot be set to a ??(feedback mode). 1: feedback output mode, the clock is driven to the pad then is feedback to the clock block. it then goes through gating logic to the qvcp block. 3 qvcp_output_enable_n r/w 1 qvcp output enable 0: output, the clock is generated internally 1: input, the clock is provided by an external source. note: during and after reset the xtal clock is forced onto the qvcp clock. in order to actually allow the input clock to go to the qvcp this register must be written to. this also implies that writing qvcp_output_enable_n = 1 overrides a sel_clk_qvcp = 0. 2:1 sel_clk_qvcp r/w 00 the following 4 settings are valid when qvcp_output_enable_n = 0. 00: clk_qvcp = 27 mhz xtal_clk (see qvcp_output_enable_n). 01: clk_qvcp = pll1 10: clk_qvcp = pll1 11: clk_qvcp = xio_ack the following 3 settings are valid when qvcp_output_enable_n = 1 (the input mode). 01: clk_qvcp_out = vdo_clk1 0 en_clk_qvcp r/w 1 1: enable clk_qvcp offset 0x04,7204 clk_qvcp_pix_ctl 31:7 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 5:3 div_clk_qvcp_pix r/w 001 000: clk_qvcp_pix_src = qvcp_clk_out clock divided by 1 001: clk_qvcp_pix_src = qvcp_clk_out clock divided by 2 010: clk_qvcp_pix_src = qvcp_clk_out clock divided by 3 011: clk_qvcp_pix_src = qvcp_clk_out clock divided by 4 100: clk_qvcp_pix_src = qvcp_clk_out clock divided by 6 101: clk_qvcp_pix_src = qvcp_clk_out clock divided by 8 (refer to figure 17 for the qvcp_clk_out) 2:1 sel_clk_qvcp_pix r/w 00 00: clk_qvcp_pix = 27 mhz xtal_clk 01: clk_qvcp_pix = clk_qvcp_pix_src 10: clk_qvcp_pix = clk_qvcp_pix_src 11: clk_qvcp_pix = xio_d[8] table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-43 0 en_clk_qvcp_pix r/w 1 1: enable clk_qvcp_pix offset 0x04,7208 clk_qvcp_proc_ctl 31:8 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 7 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 6:3 sel_clk_qvcp_proc_src r/w 0111 0000: clk_qvcp_proc_src = clk_144 0001: clk_qvcp_proc_src = clk_133 0010: clk_qvcp_proc_src = clk_108 0011: clk_qvcp_proc_src = clk_96 0100: clk_qvcp_proc_src = clk_86 0101: clk_qvcp_proc_src = clk_78 0110: clk_qvcp_proc_src = clk_58 0111: clk_qvcp_proc_src = clk_39 1000: clk_qvcp_proc_src = clk_33 1001: clk_qvcp_proc_src = clk_17 maximum speed supported is 96 mhz. other higher speeds are reserved for future use. 2:1 sel_clk_dtl_mmio r/w 00 00: clk_qvcp_proc = 27 mhz xtal_clk 01: clk_qvcp_proc = clk_qvcp_proc_src 10: clk_qvcp_proc = 27 mhz xtal_clk 11: clk_qvcp_proc = xio_d[9] 0 en_clk_proc r/w 1 1: enable clk_qvcp_proc offset 0x04,720c clk_lcd_timestamp_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_lcd_timestamp r/w 00 00: clk_lcd_timestamp = 27 mhz xtal_clk 01: clk_lcd_timestamp = 27 mhz xtal_clk 10: clk_lcd_timestamp = 27 mhz xtal_clk 11: clk_lcd_timestamp = xio_d[10] 0 en_clk_lcd_timestamp r/w 1 1: enable clk_lcd_timestamp offset 0x04,7210 clk_vip_ctl 31:5 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 4 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-44 3 vip_output_enable_n r/w 1 vip output enable 0: output, the clock is generated internally 1: input, the clock is provided by an external source unless sel_clk_vip is 00 then it is still the xtal clock. 2:1 sel_clk_vip r/w 00 00: clk_vip = 27 mhz xtal_clk (overrides vip_output_enable_n). the following is only valid when vip_output_enable_n is 0. 01: clk_vip = dds7 10: clk_vip = dds7 11: clk_vip = xio_d[11] 0 en_clk_vip r/w 1 1: enable clk_vip offset 0x04,7214 clk_vld_ctl 31:7 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 5:3 sel_clk_vld_src r/w 000 000: clk_vld_src = clk_144 001: clk_vld_src = clk_123 010: clk_vld_src = clk_108 011: clk_vld_src = clk_96 100: clk_vld_src = clk_86 101: clk_vld_src = clk_78 110: clk_vld_src = clk_72 111: clk_vld_src = clk_66 2:1 sel_clk_vld r/w 00 00: clk_vld = 27 mhz xtal_clk 01: clk_vld = clk_vld_src 10: clk_vld = 27 mhz xtal_clk 11: clk_vld = xio_d[12] 0 en_clk_vld r/w 1 1: enable clk_vld offset 0x04,7300 ai_osclk_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_ai_osclk r/w 00 00: ai_osclk = 27 mhz xtal_clk 01: ai_osclk = dds4 10: ai_osclk = 27 mhz xtal_clk 11: ai_osclk = xio_d[13] 0 en_ai_osclk r/w 1 1: enable clk_ai_osclk offset 0x04,7304 clk_ai_sck_ctl table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-45 31:3 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 2 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 1 sel_clk_ai_sck r/w 0 0: clk_ai_sck = 27 mhz xtal_clk 1: clk_ai_sck = ai_sck pin 0 en_clk_ai_sck r/w 1 1: enable clk_ai_sck offset 0x04,7308 clk_ao_osclk 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_ao_osclk r/w 00 00: ao_osclk = 27 mhz xtal_clk 01: ao_osclk = dds3 10: ao_osclk = pll1 11: ao_osclk = xio_d[14] 0 en_ao_osclk r/w 1 1: enable clk_ao_osclk offset 0x04,730c clk_ao_sck_ctl 31:3 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 2 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 1 sel_clk_ao_sck r/w 0 0: clk_ao_sck = 27 mhz xtal_clk 1: clk_ao_sck = ao_sck pin 0 en_clk_ao_sck r/w 1 1: enable clk_ao_sck offset 0x04,7310 clk_spdo_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_spdo r/w 00 00: clk_spdo = 27 mhz xtal_clk 01: clk_spdo = dds5 10: clk_spdo = 27 mhz xtal_clk 11: clk_spdo = xio_d[15] 0 en_clk_spdo r/w 1 1: enable clk_ao_osclk offset 0x04,7314 clk_spdi_ctl 31:5 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-46 4 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 3 sel_spdi_clk_src r/w 0 0: clk_spdi_src = clk_144 1: clk_spdi_src = clk_72 2:1 sel_spdi_clk r/w 00 00: clk_spdi = 27 mhz xtal_clk 01: clk_spdi = clk_spdi_src 10: clk_spdi = undef 11: clk_spdi = lan_txd[0] 0 en_clk_spdi r/w 1 1: enable clk_spdi offset 0x04,7318-0x04,73fcreserved general purpose offset 0x04,7400 clk_gpio_q4_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_gpio_q4_ctl r/w 00 00: clk_gpio_q4_ctl = 27 mhz xtal_clk 01: clk_gpio_q4_ctl = dds8 10: clk_gpio_q4_ctl = 27 mhz xtal_clk 11: clk_gpio_q4_ctl = lan_txd[1] 0 en_clk_gpio_q4_ctl r/w 1 1: enable clk_gpio_q4_ctl offset 0x04,7404 clk_gpio_q5_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_gpio_q5_ctl r/w 00 00: clk_gpio_q5_ctl = 27 mhz xtal_clk 01: clk_gpio_q5_ctl = dds7 10: clk_gpio_q5_ctl = 27 mhz xtal_clk 11: clk_gpio_q5_ctl = lan_txd[2] 0 en_clk_gpio_q5_ctl r/w 1 1: enable clk_gpio_q5_ctl offset 0x04,7408 clk_gpio_q6_12_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-47 2:1 sel_clk_gpio_q6_12_ctl r/w 00 00: clk_gpio_q6_12_ctl = 27 mhz xtal_clk 01: clk_gpio_q6_12_ctl = dds6 10: clk_gpio_q6_12_ctl = 27 mhz xtal_clk 11: clk_gpio_q6_12_ctl = lan_txd[3] 0 en_clk_gpio_q6_12_ctl r/w 1 1: enable clk_gpio_q6_12_ctl offset 0x04,740c clk_gpio_13_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_gpio_13_ctl r/w 00 00: clk_gpio_13_ctl = 27 mhz xtal_clk 01: clk_gpio_13_ctl = dds5 10: clk_gpio_13_ctl = undef 11: clk_gpio_13_ctl = lan_rxd[0] 0 en_clk_gpio_13_ctl r/w 1 1: enable clk_gpio_13_ctl offset 0x04,7410 clk_gpio_14_ctl 31:4 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 2:1 sel_clk_gpio_14_ctl r/w 00 00: clk_gpio_14_ctl = 27 mhz xtal_clk 01: clk_gpio_14_ctl = dds2 10: clk_gpio_14_ctl = undef 11: clk_gpio_14_ctl = lan_rxd[1] 0 en_clk_gpio_14_ctl r/w 1 1: enable clk_gpio_14_ctl offset 0x04,7414 clk_fgpo_ctl 31:9 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 8 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 7 invert_fgpo_clock r/w 0 invert fgpo clock 0 : do not invert the clock 1: invert the clock only to the fgpo block and not to the pad. 6 fgpo_output_select r/w 0 fgpo output select 0: seperate output mode, the clock to the fgpo and to the pad share the same source, but have seperate paths. 1: feedback output mode, the clock is driven to the pad then is feedback to the clock block. it then goes through gating logic to the fgpo block. table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-48 5 fgpo_output_enable_n r/w 1 fgpo output enable 0: output, the clock is generated internally 1: input, the clock is provided by an external source. note: during and after reset the xtal clock is forced onto the fgpo clock. in order to actually allow the input clock to go to the fgpo this register must be written to. this also implies that writing fgpo_output_enable_n = 1 overrides a sel_fgpo_clk = 0. 4:3 sel_clk_fgpo_src r/w 00 00: clk_fgpo_src = pll1 01: clk_fgpo_src = undef 10: clk_fgpo_src = dds2 11: clk_fgpo_src = clk_tm (it is not meant to be used in normal operating mode. the observation is after the output of the duty cycle stretcher, therefore it is the clock that feeds the tm3260). 2:1 sel_clk_fgpo r/w 00 the following 4 settings are valid when fgpo_output_enable_n = 0 (either of the two output modes). 00: clk_fgpo = 27 mhz xtal_clk 01: clk_fgpo = clk_fgpo_src 10: clk_fgpo = clk_fgpo_src 11: clk_fgpo = lan_rxd[2] the following 3 settings are valid when fgpo_output_enable_n = 1 (the input mode). 01: clk_fgpo = vdo_clk2 0 en_clk_fgpo r/w 1 1: enable clk_fgpo offset 0x04,7418 clk_fgpi_ctl 31:6 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 5 turn_off_ack r 0 0 - indicates if the enabled clock is running 1 - indicates that the clock is being blocked during a frequency change to avoid glitches 4 fgpi_output_enable_n r/w 1 fgpi output enable 0: output, the clock is generated internally 1: input, the clock is provided by an external source unless sel_fgpi_clk is 00 then it is xtal clock. 3 sel_clk_fgpi_src r/w 0 0: clk_fgpi_src = dds3 1: clk_fgpi_src = dds8 2:1 sel_clk_fgpi r/w 00 00: clk_fgpi = 27 mhz xtal_clk (voids fgpi_output_enable_n) only used when fgpi_output_enable_n = 0 : 01: clk_fgpi = clk_fgpi_src 10: clk_fgpi = clk_fgpi_src 11: clk_fgpi = lan_rxd[3] 0 en_clk_fgpi r/w 1 1: enable clk_fgpi offset 0x04,741c-0x04,74fcreserved debug registers offset 0x04,7500 clk_stretcher_ctl table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-49 31:0 count_stretcher_bits r/w 0 the count between clock stretches offset 0x04,7504 clk_wakeup_ctl 31:2 count_wakeup_bits r/w 0 the count to use to automatically wake-up the mmio and processor clocks. the register is a 32-bit register with the two lsb bit hard- coded to zero. if the clk_wakeup_ctl register is written with a value of 0x0000_0008. then the wake-up count will be set to a count value of 8. this means that the lowest count value is 4 (0x0000_0004 written to the clk_wakeup_ctl register) 1 external_wakeup_enabl e r/w 0 enables the use of pin gpio[15] as a wake-up event. 0 gpio_interrupt_enable r/w 0 enables the use of the gpio interrupt as an wake-up event. offset 0x04,7508 clk_freq_ctl 31:5 freq_ctr_bits r/w 0 the total time to count clock edges 4 freq_ctr_done r 1 signi?s that the count is done 3:0 en_ctr_enable r/w 1 selects which clock to count 0000: disabled 0001: pll0 0010: pll1 0011: pll2 0100: undef 0101: undef 0110: dds2 0111: dds3 1000: dds4 1001: dds5 1010: dds6 1011: dds7 1100: dds8 offset 0x04,750c clk_count_results 31:0 freq_ctr_results r - the result of the count of the clock frequency counting. offset 0x04,7510 aligner_adjust (reserved do not modify) 31:26 reserved r - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 25:24 aligner_adjust_vdo_clk2 w1 11 adjust the aligner for fgpo out (vdo_clk2) note: this clock can not have latency added to it. 23:22 aligner_adjust_area3 w1 10 adjust the aligner for the clock going to area 3 21:20 aligner_adjust_fgpo r/w1 10 adjust the aligner for fgpo out internal clock 19:18 aligner_adjust_qvcp r/w1 10 adjust the aligner for qvcp out internal clock 17:16 aligner_adjust_qvcp_pix r/w1 10 adjust the aligner for qvcp pix clock 15:14 aligner_adjust_qvcp_out r/w1 10 adjust the aligner for qvcp out (vdo_clk1) 13:12 aligner_adjust_area7 r/w1 10 adjust the aligner for the clock going to area 7 11:10 aligner_adjust_area6 r/w1 10 adjust the aligner for the clock going to area 6 table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-50 9:8 aligner_adjust_area2 r/w1 10 adjust the aligner for the clock going to area 2 7:6 aligner_adjust_area1 r/w1 10 adjust the aligner for the clock going to area 1 5:4 aligner_adjust_l_area0 r/w1 10 adjust the aligner for the late clock going to area 0 3:2 aligner_adjust_e_area0 r/w1 10 adjust the aligner for the early clock going to area 0 1:0 aligner_adjust r/w1 10 adjust the aligner for the 3ns aligner the below values apply to each of the above except the 25:24 bits 11 : adds to the clock latency 01, 10 : medium clock latency (default) 00 : decreases the clock latency offset 0x04,7514-fdc reserved interrupt registers offset 0x04,7fe0 interrupt status 31 vdo_clk2_present r 0 1: clock present 0: clock not present 30 vdi_clk2_present r 0 1: clock present 0: clock not present 29 ao_sckin_present r 0 1: clock present 0: clock not present 28 ai_sckin_present r 0 1: clock present 0: clock not present 27 vdi_clk1_present r 0 1: clock present 0: clock not present 20:5 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 4 vdo_clk2 (clk_fgpo) r 0 1: clock interrupt 3 vdi_clk2 (clk_fgpi) r 0 1: clock interrupt 2 ao_sck r 0 1: clock interrupt 1 ai_sck r 0 1: clock interrupt 0 vdi_clk1 (clk_vip) r 0 1: clock interrupt offset 0x04,7fe4 interrupt enable 31:5 reserved r/w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 4 vdo_clk2 (clk_fgpo) r/w 0 1: interrupt enabled 0: interrupt not enabled 3 vdi_clk2 (clk_fgpi) r/w 0 1: interrupt enabled 0: interrupt not enabled 2 ao_sck r/w 0 1: interrupt enabled 0: interrupt not enabled 1 ai_sck r/w 0 1: interrupt enabled 0: interrupt not enabled table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-51 0 vdi_clk1 (clk_vip) r/w 0 1: interrupt enabled 0: interrupt not enabled offset 0x04,7fe8 interrupt clear 31:5 reserved w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 4 vdo_clk2 (clk_fgpo) w 0 1: clear interrupt 3 vdi_clk2 (clk_fgpi) w 0 1: clear interrupt 2 ao_sck w 0 1: clear interrupt 1 ai_sck w 0 1: clear interrupt 0 vdi_clk1 (clk_vip) w 0 1: clear interrupt offset 0x04,7fec set interrupt 31:15 reserved w - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 4 vdo_clk2 (clk_fgpo) w 0 1: set interrupt 3 vdi_clk2 (clk_fgpi) w 0 1: set interrupt 2 ao_sck w 0 1: set interrupt 1 ai_sck w 0 1: set interrupt 0 vdi_clk1 (clk_vip) w 0 1: set interrupt offset 0x04,7ff0-ff8 reserved offset 0x04,7ffc module_id 31:16 module_id r 0xa063 module id 15:8 module_id r 0 major_rev id 7:0 module_id r 0 minor_rev id table 11: clock module registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 5: the clock module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 5-52
1. introduction before a pnx15xx series system can begin operating, there are a couple of system related mmio registers, chapter 3 system on chip resources , but also the main pnx15xx series interfaces like the main memory interface (mmi) or the pci that require to be con?ured. since the tm3260 cannot begin operating before these registers and circuits are initialized, the tm3260 cannot be relied on to initialize these resources. consequently, pnx15xx series needs an independent bootstrap facility for low-level initialization: the boot module. the boot module provides boot scripts to reduce the board system cost. the scripts allow support for both host-assisted mode, and standalone boot mode. the supported four boot modes are: boot from an external eeprom attached on the i 2 c bus interface. the eeprom contains a list of mmio registers and memory locations to be written. boot for host-assisted systems. the host cpu kicks off tm3260. therefore the host is in charge of downloading the tm3260 binary program and in charge of setting properly the remaining of the system. boot from nand or nor flash memory devices. the ?st 8 kilobytes of the flash memory contains the bootstrapping program for tm3260. the flash memory can be 8- or 16-bit wide. the different modes are determined by the gpio[11:8,3:0]/boot_mode[7:0] pins. once the boot procedure is complete, the boot module goes to sleep until another system reset event occurs, see chapter 4 reset . 2. functional description the pnx15xx series boot sequence begins with the assertion of the system reset. the system reset is seen by the boot module through the internal signal peri_rst_n. after this internal reset is de-asserted only the system boot block and the pci interfaces are allowed to operate. in particular, the tm3260 remains in the reset state until it is explicitly released from reset during or after the boot procedure. in the standalone boot mode the system boot module is responsible for releasing the tm3260 from the reset state. in host-assisted boot the boot logic releases the pnx15xx series system from reset such that the pnx15xx series software driver (which runs on the host processor) can ?ish the con?uration of the pnx15xx series system, download the tm3260 binary code and then release the tm3260 from its reset state. chapter 6: boot module pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-2 2.1 the boot modes the boot modes are de?ed by the state of the boot_mode[7:0] pins at reset time. therefore adequate pull-ups and pull-downs should be placed on the system board in order to select the correct mode. once the internal signal peri_rst_n is released, the boot_mode[7:0] pins are sampled. the sampling mechanism delays the peri_rst_n signal by two clk_27 (the initial 27 mhz clock) periods and delays the sampling of the boot_mode[7:0] pins by ?e clk_27 periods. this ensures the correct values of the boot_mode pins are latched properly, since after the reset goes away, the values on the gpio pins may become indeterministic. the different boot modes based on the state of the boot_mode[7:0] pins is described in the following t ab le 1 . table 1: the boot modes boot_mode bits gpio pins default function description 7 11 - en_pci_arb 1 - enables the internal pci system arbiter 0 - disables the internal pci system arbiter 6:4 10:8 - mem_size informs the boot scripts of the total memory size available on the system board. this information is crucial to properly set-up the pci con?uration management in host-assisted mode. the pin code is as follows: 000 - 2mb 001 - 4mb 010 - 8mb 011 - 16mb 100 - 32mb 101 - 64mb 110 - 128mb 111 - 256mb
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-3 the default state of the boot_mode[3:0] pins may be determined by the internal pull-ups and pull-downs presents in the i/os of pnx15xx series. however the boot_mode[7:4] pins must be pulled up or down at board level to ensure a proper boot function. 3 3 0x0 cas_latency ddr sdram devices support different types of cas latencies. however they do not support all the combinations. pnx15xx series offers the possibility to program the mmi (and therefore the ddr sdram devices) with the appropriate cas latency at boot time. this is crucial for standalone boot from flash memories devices since 8 kilobytes of data is stored into the main memory during the execution of the boot scripts. 0 - 2.5 clock periods 1 - 3 clocks periods 2 2 0x1 rom_width/ iic_fastmode this pin has a dual functional mode: if boot_mode[1:0] = ?0? ?1? or ?0?(boot from flash memory) 0 - 8-bit data wide rom 1 - 16-bit data wide rom if boot_mode[1:0] = ?1?(boot from i 2 c eeprom) 0 - 100 khz 1 - 400 khz 1:0 1:0 0x3 boot_mode the main boot mode is determined as follows: 00 - set up the system and start the tm3260 cpu from a 8- or 16- bit nor flash memory or rom attached to the pci-xio bus. 01 - set up the system and start the tm3260 cpu from a 8- or 16- bit nand flash memory or rom attached to the pci-xio bus. 10 - set up the pnx15xx series system in host-assisted mode and allow the host cpu to ?ish the con?uration of the pnx15xx series system and start the tm3260 cpu. 11 - boot from an i 2 c eeprom attached to the i 2 c interface. eeproms of 2 to 64 kilobytes are supported. the entire system can be initialized in a custom fashion by the boot commands contained in the eeprom. this mode can be used for standalone or host-assisted boot mode when the other internal boot scripts are not meeting the speci? requirements of the application. in this mode the boot script is in the eeprom. refer to section 2.3 for further details on the eeprom content. table 1: the boot modes ?ontinued boot_mode bits gpio pins default function description
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-4 2.2 boot module operation the following presents a high level block diagram of the boot module. the four main components of the boot module are: 1. the mmio to the dcs bus interface. 2. the i 2 c master interface & control. 3. the boot control & state machine. 4. the internal scripts (detailed in section 3. ) 2.2.1 mmio bus interface the mmio bus sub-module contains only the master interface. therefore despite the general rule there is no module_id for the boot module and the master interface module can only perform writes. it does not perform reads from other modules sitting on the dcs bus. as a master, this module writes full 32-bit words to the dcs bus. these write requests are then routed to the appropriate mmio register or to the mmi. 2.2.2 i 2 c master depending on the state of the bootmode[1:0] pins, the i 2 c master interface gets activated after the reset is released. if the bootmode[1:0] is equal to 0x3 then the boot module takes over the control of the i 2 c interface. the data received from the external eeprom is decoded by the boot state machine. the mmio bus sub-module is activated to write data on the dcs bus per the command encoding described in section 2.3 . the i 2 c master does not arbitrate for the i 2 c bus since it is expected that there will be no other bus masters during the boot process. however, the i 2 c master does allow clock stretching by the slave (here the eeprom). the clock stretching is not expected from the eeprom but the feature is there in order to meet the i 2 c figure 1: boot block diagram #2 optional 2 to 64 kilobytes eeprom with custom reset module pnx15xx internal boot script #1 boot module mmio to dcs bus interface peri_rst_n 27 mhz (clk_27) 2 8 boot_mode[7:0] dcs bus i 2 c i 2 c control
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-5 speci?ation. depending on the state of the boot_mode[2] pin the operating speed of the i 2 c interface is 400 khz, if set to ?? or 100 khz, if set to ?? the i 2 c master derives the 100 khz or 400 khz clock from 27 mhz input clock. the i 2 c interface can handle eeproms with both 1-byte and 2-byte addressing formats. 2.2.3 boot control/state machine the boot control/state machine is in fact a mini processor. it fetches commands from the boot scripts or the content of the eeprom, decodes the command and processes the address or the data depending on the command as documented section 2.3 . when an end of boot command is reached, the i 2 c interface is released and can later on be used by the i 2 c module. 2.3 the boot command language the boot script consists of a sequence of 32-bit commands. these commands constitute the language understood by the boot module. the valid commands are: a write to a given 32-bit value at a given address (useful for writing device control registers). a write to an arbitrary length list of 32-bit values starting at a given address (useful for ?ling memory with a processor binary image). a delay by a given number of 27 mhz clock ticks (useful to wait for completion of an action, such as a pll frequency change, or a device dma operation). terminate boot.
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-6 the following t ab le 2 documents the coding of the four commands. 3. pnx15xx series boot scripts content unlike pnx1300 series systems [1], pnx15xx series uses internal boot scripts to provide some cost savings at board level by allowing the building of products without the need of an external eeprom. the following sections describes the content of these scripts. if the content of these internal boot scripts is not suitable for the pnx15xx series based product, then an eeprom should be used to override the internal boot scripts, see section 4. . 3.1 the common behavior the three scripts have a common section which is the initial con?uration sequence of the pnx15xx series system. the differences between the boot scripts is detailed in the next sections. the common behavior is described bellow in the order in which it happens: 1. enable the clocks for the tm3260, 100 mhz, and the mmi, 125 mhz, modules. 2. enable the clocks for the mmio bus (a.k.a. the dcs bus), 102 mhz, and the pci_sys_clk, 33.23 mhz, clocks. table 2: the boot commands command encoding (32 bits each) description write(address,value) address: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 00 value: vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv write a single 32-bit value, ??at address ??(32-bit word aligned) mmio bus or memory address. ??is the 30-bit value composed by the bits concatenated with two 0s (makes it a 32-bit word address). ??is the 32-bit value composed by the bits. writelist(a,lenght,valarray) address: aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa 01 length: nnnnnnnnnnnnnnnnnnnnnnnnnnnnn value<1>: vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv value<2>: vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv . . value: vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv write an arbitrary length list of 32-bit values, value<1>,..., value, starting at address ??(32- bit aligned) mmio bus or memory address. value<1> is written at address ??+ 0, value is written at the 32-bit word address ?+n-1? ??is the 30-bit value composed by the bits concatenated with two 0s (makes it a 32-bit word address). delay(ncycles) nnnnnnnnnnnnnnnnnnnnnnnnnnnn 0010 delay by n 27 mhz cycle periods. where n is the 28-bit value composed by the bits. terminate boot nnnnnnnnnnnnnnnnnnnnnnnnnnnn 0110 end boot process. the boot module releases i2c bus and becomes non-active until a hardware reset or software reset occurs. xxxxxxxxxxxxxxxxxxxxxxxxxxxx1x1x reserved for future use.
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-7 3. con?ure the mmi with default ddr sdram timing parameter settings that support as many dram vendors as possible. it is recommended to verify these default parameters comply with the ddr sdram devices used to build the pnx15xx series system board. not all the mmi parameters are initialized in the boot scripts some are the reset defaults of the mmi module. the t ab le 3 summarizes the values of ddr sdram timing parameters once the con?urations of the mmi is completed by the boot. it is then the tm3260 or the host cpu that is in charge to ?e tune these parameters by re-programming the mmi module according to the ddr sdram devices used on the pnx15xx series system board. furthermore row_width and column_width have been set to 11 and 8, respectively, which allows the use of any kind of ddr sdram densities and con?urations during the boot process (i.e. in standalone only 8 kilobytes of data is written to memory). finally, some parameters are dependant on the cas latency of the devices. after review of different ddr sdram device datasheets, it is found that devices organized in x32 support, at least, cas latencies of 3.0. similarly the devices organized in x16 support at least a cas latencies of 2.5. in addition to the cas latencies the x32 and x16 devices require some different settings for the auto-precharge bit. therefore pnx15xx series boot_mode[3] pin is also used to determine if a x32 or x16 devices are used in the board system. this assumption is not bullet proof but works for most of the ddr sdram vendors.the boot scripts assume a x32 device when cas latency is 3.0 and a x16 device when the latency is 2.5. t ab le 4 shows the mmi parameters affected by the boot_mode[3] pin, a.k.a. cas_latency. table 3: default ddr sdram timing parameters parameter value (clocks) trcd read 4 trcd write 4 trrd 4 tmrd 4 twtr 1 twr 3 trp 4 tras 9 trfc 15 trc 13 table 4: cas latency related ddr sdram timing parameters parameter cas_latency = 3.0 cas_latency = 2.5 precharge_bit 8 10 tcas 6 5
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-8 4. in all cases the pci modules pci setup and pci command registers are programmed as shown in t ab le 5 . 5. the next step is to con?ure the pci-xio module to fetch data from the flash memory devices connected to the pci-xio bus if pnx15xx series is con?ured in standalone mode, see next step in section 3.2 . the other option is to con?ure the pnx15xx series in host-assisted mode, see section 3.3 . 6. the ?al step is obviously to send a terminate boot command. the next section 3.1.1 contains the content in hexadecimal of the common boot scripts. table 5: pci setup and pci command register content parameter bit field values comments en_pci2mmi 1 pci master can write to pnx15xx series ddr sdram. en_xio 1 xio operations are enabled base18_prefetchable 0 base18_size 5 64 megabytes en_base18 1 xio aperture is enabled base14_prefetchable 0 base14_size 000 2 megabytes en_base14 1 mmio aperture is enabled base10_prefetchable 0 base10_size boot_mode[6:4] pins con?ured at pin level, see t ab le 1 . en_config_manag 1 pci con?uration is authorized en_pci_arb boot_mode[7] pin con?ured at pin level, see t ab le 1 . bus_master 1 pci command register memory_space 1 pci command register
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-9 3.1.1 binary sequence for the common boot script table 6: binary sequence for the common boot script cas_latency = 3.0 cas_latency = 2.5 comments 0x1be4_7101 0x0000_0002 0x0000_0003 0x0000_0003 0x1be4_712c 0x0000_0003 0x1be4_710c 0x0000_0003 0x1be6_5004 0x0000_0003 0x1be6_50c0 0x0000_000b 0x1be6_50c4 0x0000_0008 0x1be6_5088 tm3260 clock mmi clock mmio clock pci_sys_clk clock mmi def_bank_switch mmi row_width mmi column_width 0x0000_0008 0x0000_000a mmi precharge_bit: boot_mode[3] 0x8 for x32 devices, and cas latency 3.0 0xa for x16 devices, and cas latency 2.5 0x1be6_5080 0x0000_0133 0x0000_0163 mmi mr 0x1be6_5128 0x0000_0006 0x0000_0005 mmi tcas 0x1be6_512c 0x0000_0760 0x1be6_5000 mmi rf_period 0x0000_0001 0x0000_000d mmi ctl 0x1be6_5100 0x0004_0004 0x1be6_511c 0x0000_0004 0x1be6_5124 0x0000_0004 mmi trcd mmi trrd mmi tmrd 0x1be4_0010 0x01d60f03 the value of pci_setup depends on the boot_mode[7:4] pins. in this example: 128 mb dram aperture internal pci arbiter enabled 0x1be4_0044 0x0000_0006 pci command register section 3.2 or section 3.3 0x0000_0006 terminate boot
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-10 3.2 the speci?s of the boot from flash memory devices in standalone mode pnx15xx series fetches its tm3260 binary program and data from a flash memory device. the pci module has internal dma logic that allows, with few mmio register writes, to autonomously fetch data from flash memory devices (connected to the pci-xio bus) to the main memory. the typical simpli?d board system is sketched in figure 2 . the aperture settings are also presented in the same figure 2 . the size of the dram is programmable with bootstrap options (resistor pull-up or -down) on the boot_mode[6:4] pins. the flash memory device used for boot must be connected and therefore selectable by the xio_sel0 pin. in order to be able to access the content of the flash memory devices the following actions are taken in the boot scripts: 1. the xio_ack and the xio_d[15:8] are removed from their reset state that sets them as gpio pins. this is done whether the connected flash memory device is 8- or 16-bit wide. 2. the pci module dma is con?ured depending on the boot_mode[2:0] pin value. based on the values of these pins the pci module knows the width and type of the flash memory device. t ab le 7 describes the different settings used to access the two types of flash memory devices. the xio sel0 pro?e mmio figure 2: system memory map and block diagram con?uration for pnx15xx series in standalone mode 0xffff,ffff pnx15xx boot_mode[7:0] xio_sel0 pci agent/slave ddr sdram pci-xio bus 8- or 16-bit nand or nor flash/rom 0x1be0_0000 0x0xx0_0000 0x0000_0000 0x1c00_0000 0x2000_0000 8-256 mb dram 2 mb mmio 64 mb xio unused unused
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-11 register and the dma controls mmio register are the two mmio registers modi?d by the boot script. the remaining mmio registers use the reset state of the pci module. 3. the boot module executes an idle loop to wait for the completion of the fetched data from the flash memory device to the main memory. 4. the last step before completing the terminate boot command is to set up the tm3260 dram aperture registers and kick off the tm3260 cpu. the next section 3.3.1.1 contains the content, in hexadecimal, of the flash boot scripts. table 7: flash timing parameters used by the default boot scripts nor flash nand flash parameter bit field value comment bit field value comment misc_ctrl 0 0 sel0_16bit boot_mode[2] pin boot_mode[2] pin sel0_use_ack 0 fixed wait states 1 wait for ack sel0_we_hi 0 n/a 0xa 10 pci clock cycles of high and low time for ren sel0_we_lo 0 n/a 0xa 10 pci clock cycles of high and low time for ren sel0_wait 6 6 pci clock cycles for the output enable signal 2 2 pci clock cycles for the address to data phase delay sel0_offset 0 no offset 0 no offset sel0_type 1 nor flash 2 nand flash sel0_siz 0 8 megabytes 0 8 megabytes en_sel0 1 enabled 1 enabled single_data_phase 0 0 snd2xio 1 target xio 1 target xio fix_addr 0 linear address 0 linear address max_burst_size 4 128 data phases 4 128 data phases init_dma 1 start to fetch data 1 start to fetch data cmd_type 6 xio read command 6 xio read command
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-12 3.2.1 binary sequence for the section of the flash boot 3.3 the speci?s of the host-assisted mode in host-assisted boot mode the pnx15xx series is in a con?uration where an external cpu, such as an external mips tm , x86, powerpc tm , or sh-5 tm is the host. in that case, the pnx15xx series behaves as a plug-in pci device. most of the responsibility of booting is taken care of by the host pci bios and by the pnx15xx series driver. however, there is still a requirement for a boot script in order to initialize the hardware and get it ready to act as a recognizable pci device. in addition to the common boot script sequence, the only extra step required is to set a: pci subsystem vendor id. this is a 16-bit value that identi?s the board vendor. philips has the code 0x1131. manufacturers of pci plug-in cards for the open market must obtain and use their own id (from the pci special interest group)[2]. subsystem id. this is a 16-bit value established by the board vendor to identify a particular board. this is allocated by the vendors pci special interest group representative. this value is used to identify a suitable driver for pc plug-and- play. since these ids are vendor speci? any pci plug-in board based on pnx15xx series requires an external eeprom. this eeprom has the responsibility to bring the system into a good initial state (can be similar to the data presented in section 3.1.1 ) and to personalize the subsystem id and subsystem vendor id. table 8: binary sequence for the section of the flash boot nor flash nand flash comments 8-bit mode 16-bit mode 8-bit mode 16-bit mode 0x1bf0_4005 0x0000_0002 0x5550_0000 0x0000_0155 enables the functional mode of xio_ack and xio_d[15:8] pins instead of the gpio mode (default after reset). 0x1be4_0814 0x0000_0c09 0x0080_0c09 0x006a_8411 0x00ea_8411 xio pro?e 0 0x1be4_080c 0x0000_0296 start the 8-kilobyte data fetch from the flash memory device. 0x000f_0002 0x0007_8002 0x000a_8002 0x0006_1282 waits for the completion of the 8-kilobyte fetch. 0x1bf0_0038 tm32_dram_hi 0x1bf0_0048 0x0010_0000 0x1bf0_0030 0x8000_0000 tm32_dram_hi depends upon the state of the boot_mode[6:4] pins. tm3260 starts executing code from tm32_dram_start set to 1 megabyte. start tm3260.
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-13 the pnx15xx series boot system also provides a host-assisted boot script for standalone board system (i.e. not a pci plug-in card) that use pnx15xx series in host-assisted mode. since the pci bus of this standalone board system is not visible by the rest of the world it is possible to assign a default value and let the host driver recognize a pnx15xx series system with the following ids: finally on a pci bus the sizes for all the apertures must be given an unique physical addresses at pci bios device enumeration time (dram, mmio and xio for the pnx15xx series). this is the work of the host pci bios driver. remark: the aperture sizes are written at boot time into the pci module mmio registers. the host pci bios software retrieves the values by a write, followed by a read to the pci configuration space base address registers. it then assigns a suitable value to each base address. refer to [2], section 6.2.5.1, ?ddress maps for more details. a typical simpli?d board system is sketched in figure 3 . the aperture allocation seen in the figure 3 is an example of how the host bios can set the location of the apertures. table 9: host con?uration sequence boot script content comments 0x1be4_0010 (0x7583<<10) | (dram_size<<7) | en_pci_arb pci setup register depends on gpio[11:8] 0x1be4_006c 0x0009_1131 pci subsystem id is 0x0009 pci subsystem vendor id is 0x1131 figure 3: system memory map and block diagram con?uration for pnx15xx series in host-assisted mode 0xffff,ffff pnx15xx boot_mode[7:0] pci agent/slave ddr sdram pci-xio bus all set by the host bios pci agent/slave pci agent/slave ram flash host cpu bridge boot eeprom (optional) i2c base_14 mmio_base base_10 dram_base 0x0000,0000 8-128 mb xio 8-256 mb dram 2 mb mmio base_18 xio_base
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-14 4. the boot from an i 2 c eeprom if none of the built-in scripts is suitable e.g., due to a different type of nand-flash or a different memory organization or anything not matching the internal boot scripts, an external serial boot eeprom is required. depending on the application characteristics, this can be a small (1 kilobyte or less) eeprom that contains a small boot script and starts the pnx15xx series system in host-assisted mode or boot from flash memory or rom devices. alternately, a large serial eeprom can be used to contain a complete disk ?e system or an upload capability from another device than flash/rom. for a 2-kilobyte or smaller eeprom, the script must start at byte address 1 (not 0). for a 4-kilobyte or larger eeprom, the boot script must start at byte address 0. more details in section 4.3 . each set of four successive bytes is assembled into a 32-bit word value (the byte read ?st ends up as the least signi?ant byte, lbs). the 32-bit words are then interpreted as commands, as documented earlier in section 2.3 . remark: it has been seen that depending on the write protect pin status, some eeproms do not behave the same way on a write of 0 bytes ( s e c t i o n 4 . 3 ). the internal counter gets or does not get incremented which makes this rule of where the first byte is located at address 0 or 1 different. refer to eeprom datasheet or try both options. 4.1 external i 2 c boot eeprom types the pnx15xx series boot module supports all i 2 c eeproms (sometimes called 2- wire eeproms) that use a 1-byte or 2-byte address protocol and respond to an i 2 c device code 1010 (binary). subtle differences exist between devices for example: it is recommended to avoid devices that have partial array write protection, since such devices could be overwritten by accidental or intentional i 2 c writes, causing boot failure during the next reset. some devices may have additional functionality that is useful, like a watchdog timer or a power voltage drop sensor. availability from different vendors may vary. programming protocols may vary. t ab le 10 lists a variety of devices. this list is by no means exhaustive, nor has operation for all these devices been veri?d. table 10: examples of i 2 c eeprom devices size device write protection coverage address protocol comment 256 bytes atmel 24c02 full array 1 byte 512 bytes atmel 24c04 full array 1 byte 1 kilobytes atmel 24c08 full array 1 byte tested 2 kilobytes philips pcf85116-3 full array 1 byte 2 kilobytes summit sms8198 full array 1 byte includes power-on reset for board system reset generation
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-15 4.2 the boot commands and the endian mode when writing to an mmio register address, there is no endian mode issue. the msbit of the word ? ( t ab le 2 ) end up as the msbit of the mmio register. when writing to an sdram address there is an endian mode issue. depending on the current endian mode ( section 4. on page 3- 8 ), 32-bit words get written to memory through the dcs dram gate ( section 2.3 on page 3- 4 ) in one of these two ways: in little-endian mode, the msb of ? (or the last read eeprom byte of the word), end up in memory byte address ?+3 and lsb (or ?st read eeprom byte), end up at the byte address ?? in big-endian mode, the msb of ??(or last read eeprom byte), end up at the byte address ??and the lsb (or ?st read eeprom byte), end up at the byte address ?+3? 4.3 details on i 2 c operation to retrieve the boot script, the boot module performs the following i 2 c transactions: start, 1010000, wait-for-ack, 00000000, wait-for-ack, 00000000, wait-for-ack, stop start, 1010001, wait-for-ack, . the interpretation of this sequence by 2048 bytes or smaller eeproms is: write a byte value 0 to address 0 (setting the next address-pointer to byte address 1). read, starting from address 1. hence, for a 2048-byte or smaller eeprom, the boot image must start at byte 1. the interpretation of this sequence by 4096 bytes or larger eeproms is: write a 0 byte-long sequence to address 0 (setting next address pointer to byte address 0). read, starting from address 0. hence, for a 4096-byte or larger eeprom, the boot image must start at byte 0. 16 kilobytes atmel 24c128 full array 2 bytes 32 kilobytes atmel 24c256 full array 2 bytes tested 64 kilobytes atmel 24c512 full array 2 bytes table 10: examples of i 2 c eeprom devices size device write protection coverage address protocol comment
philips semiconductors pnx15xx series volume 1 of 1 chapter 6: boot module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 6-16 5. references [1] ?nx1300 series media processor? feb. 15th 2002, philips semiconductors, inc. [2] ?ci local bus speci?ation, rev 2.2? dec. 18th, 1998, pci special interest group.
1. introduction pnx15xx series includes a pci interface for easy integration into personal computer applications (where the pci-bus is the standard for high-speed peripherals). in embedded applications the pci bus can interface to peripheral devices that implement functions not provided by the on-chip modules or to connected several cpus together. the main function of the pci interface is to connect the pnx15xx series on-chip mtl bus (and therefore its main memory) and its internal registers to the rest of the world. a bus cycle on pci that targets an address mapped into pnx15xx series memory space will cause the pci interface to create a mtl bus cycle targeted at dram. from pnx15xx series, only the tm3260 cpu can cause the pci interface to create pci bus cycles; the other on-chip modules cannot see external hardware through the pci interface. from pci, dram and most of the registers in mmio space can be accessed by external pci initiators. the pci interface implements dma (also called block or burst transfers) and non- dma transfers. dma transfers are interruptible on 64-byte boundaries. the pci interface can service outbound (pnx15xx series pci) and inbound (pci pnx15xx series) data ?ws simultaneously. the following classes of operations invoked by pnx15xx series cause the pci interface to act as a pci initiator: transparent, single-word (or smaller) transactions caused by tm3260 loads and stores to one of the two available the pci address aperture, pci1 and pci2. explicitly programmed single-word i/o or con?uration read or write transactions explicitly programmed multi-word dma transactions. the pnx15xx series pci interface responds as a target to external initiators for a limited set of pci transaction types: con?uration read/write. memory read/write, read line, and read multiple to the pnx15xx series dram or mmio apertures. pnx15xx series ignores pci transactions other than the above. chapter 7: pci-xio module pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-2 the pci-xio module also includes an xio interface. the xio interface ?teals pci cycle?to run xio transfers before giving control back to pci. the xio interface supports ide, nand and nor type flash and motorola devices, in 8- or 16-bit datapath. 2. functional description the document title variable module supports 33 mhz pci spec version 2.2. it can operate as a con?uration manager or it can also act as a target to external con?uration cycles when an external processor and north bridge are used in the system. features: three base addresses, i.e. apertures, are supported. option to enable internal pci system arbiter which can support up to three external pci masters. as a pci master, it can generate all non-reserved types of single transaction pci cycles: io, memory, interrupt acknowledge and con?uration cycle. linear burst mode is supported on memory transactions. other burst mode transfers are terminated after a single data transfer. a dma engine provides high speed transfer to and from sdram and an external pci device. the dma can also be used to transfer data to and from xio devices. the pci clock and pci_rst are generated externally and input to this module. in pci terminology it is a single function device. the following general pci features are not implemented in the document title variable module: as a pci target, the device only responds to memory and con?uration cycles. subtractive decoding is not supported. there is no hard-coded legacy decoding of address space (such as vga io and memory). burst to con?uration space is not supported.
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-3 2.1 document title variable block level diagram 2.2 architecture supported commands on the document title variable are shown in the following table: figure 1: document title variable block diagram pci config & mmio regs pcir dtl target dma agent gpxio agent gppm agent dtl agent internal arbitration xio dtl target xio pci2 dtl target pci1 dtl target pci dtl initiator pci slave system arbitration pci master pci dma dtl initiator dma dtl initiator dcs dcs dc s dcs dcs mtl mtl table 1: supported pci commands command: pci target responses command: pci master generates memory read io read memory write io write con?uration read memory read con?uration write memory write memory read multiple con?uration read memory read line con?uration write [1] memory write and invalidate memory read multiple memory read line memory write and invalidate interrupt acknowledge
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-4 3. operation 3.1 overview the document title variable module supports the 33 mhz pci spec version 2.2. access from external masters may be restricted to word-only if desired. when this feature is enabled, attempted access with less than a word will result in the pci slave terminating the transaction with a target abort or ignoring the write and returning 0 on read. this behavior is determined by a con?uration switch. when the pci device can not return data on reads within 16 pci clocks, the transactions will terminate in a retry. the read will be completed internally and the pci will hold the data exclusively for the initiating agent for the duration of the ?ead_lifetime timer. no other read will be accepted while the timer is active. after the timer expires, any read request will be accepted. the saved data will be tossed if a different master requests a read. any xio device(s) can be accessed any time after the pci con?uration space has been initialized. to be pci compliant, it will monitor the internal address rather than the io pads. at this time, an xio cycle is run on the pci pins. pci pins ad[23:0] present the address to the device while ad[31:24] contain the data. the pci cbe pins are used for xio control. there are ?e dedicated pins to be used as chip selects to the device(s). the following table shows how the xio supports various 8- and 16-bit xio devices. [1] con?uration write can be initiated only when con?uration management is enabled. table 2: xio pin multiplexing signals i/o 68360 16-bit 68360 8-bit nor ?sh 16-bit nor flash 8-bit nand-?sh 16-bit nand-flash 8-bit ide pci signals devsel# i/o na na na na na na na frame# i/o na na na na na na na irdy# i/o na na na na na na na trdy# i/o na na na na na na na stop# i/o na na na na na na na idsel i na na na na na na na par i/o na na na na na na na perr# i/o na na na na na na na serr# i/o na na na na na na na req_a# i na na na na na na na req_b# i dsack dsack na na na na na req# i/o na na na na na na na gnt_a# o na na na na na na na
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-5 3.1.1 nand-flash interface operation interfacing to a nand-flash involves both hardware setup and software support. the hardware support is designed to be very ?xible in supporting the standard devices plus extensions that may be provided by some ?sh vendors. t ab le 3 shows recommended settings for the hardware con?ured for various nand-flash operations. a nand transaction may consist of 0, 1, or 2 command phases and 0, 1, 2, 3 or 4 address phases, and n data phases. the sequence is as follows: ?st command, low address (address bits [7:0]), middle address (address bits [16:8]), high address gnt_b# o na na na na na na na gnt# i/o na na na na na na na ad[31:24] i/o d[7:0] d[7:0] d[7:0] d[7:0] ad[7:0] ad[7:0] d[7:0] ad[23:16] i/o a[23:16] a[23:16] a[23:16] a[23:16] d[15:8] na d[15:8] ad[15] i/o a[15] a[15] a[15] a[15] na na cs1 ad[14] i/o a[14] a[14] a[14] a[14] na na cs0 ad[13:11] i/o a[13:11] a[13:11] a[13:11] a[13:11] na na a[2:0] ad[10] i/o a[10] a[10] a[10] a[10] na na diow ad[9] i/o a[9] a[9] a[9] a[9] na na dior ad[8] i/o a[8] a[8] a[8] a[8] na na data_dir ad[7:2] i/o a[7:2] a[7:2] a[7:2] a[7:2] na na na ad[1] i/o a[1] a[1] a[1] a[1] ale ale na ad[0] i/o a[0] a[0] a[0] a[0] cle cle iordy cbe3# i/o a[24] a[24] a[24] a[24] na na na cbe2# i/o as as oen oen ren ren na cbe1# i/o r/wn r/wn wn wn wen wen na cbe0# i/o ds ds na na na na na xio signals xio_a[25] o a[25] a[25] a[25] a[25] na na na xio_ack i na na r/bn r/bn r/bn r/bn na xio_sel0,1, 2,3,4 ocscscecece ce ce xio_dat[15:8] i/o d[15:8] na d[15:8] na na na na gpio signals intreq is an input for ide style xio. it may be connected to any available gpio. this signal is then routed to the tm3260 vic interrupt controller. or any of the direct interrupt lines can be used. see interrupt assignments in section 6.1 on page 3- 12 . table 2: xio pin multiplexing ?ontinued signals i/o 68360 16-bit 68360 8-bit nor ?sh 16-bit nor flash 8-bit nand-?sh 16-bit nand-flash 8-bit ide
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-6 (address bits [24:17]), data, second command. for transactions with fewer than three address phases, low address is ?st dropped, then middle address. any transaction that includes an address phase must include at least one command phase. with a direct access to the nand, n is limited to 4 bytes. using the dma, n is limited to the segment length, 512 or 528 bytes with spare area. this is to allow time for the busy signal to become stable at segment boundaries. the dma may be programmed to read much larger areas if the nand does not assert its busy state or is allowed to pause at segment boundaries. programmers should consult the vendors data sheet for the appropriate nand-flash selection. the wen and ren timing information will also be found in the data sheets. the document title variable module supports read pro?es with low time from 1 to 4 pci clock periods. write pro?es of 1 to 4 pci clock periods is supported for command and address writes. data writes must use a high time of at least 2 pci clock periods. if data is not part of the transaction, the second command will follow the last address phase. the ack signal is monitored, when enabled, only at predetermined parts of the transaction. during read operations, it will monitor the ack after the last address phase, before the read begins. the ?ed delay must be programmed to a value suf?ient to allow the ack to become valid before sampling it. this should include time to double synchronize the ack to the pci clock. the ack is also sampled before starting a nand transaction (but after the pci wrapper has started). this applies to all types of transactions. even a status read will stall until the device is ready if monitor ack is enabled when starting the nand transaction. the read data operation may be done by blending dma and direct access to minimize the time the pci bus is blocked from other types of transactions. to do this, set the pro?e to issue 1 command, 3 address phase, and no data. also load the appropriate command into the command a register. next do a write to the starting address of interest. change the pro?e to 0 command, 0 address, include data. the dma should be programmed to transfer the selected amount of data to sdram. if the dma is started before the device is ready, it will stall until the device is ready. table 3: recommended settings for nand description cmd no. addr no. include data monitor ack cmd a cmd b notes read data 1 3 [1] y y 00h or 01h na recommended to use dma. this may be set to more than one segment if restricting max_burst_size to 128. read id 1 1 y n 90h na recommended to use direct (or indirect) access. read status 1 0 y n 70h na may read up to four bytes of status with direct access. write data 2 3 [1] y y 80h 10h recommended to use dma. block erase 2 2 [1] n y 60h d0h recommended to use direct (or indirect) access. reset 1 0 n n ffh na recommended to use direct (or indirect) access. [1] 64-mb devices will require more address phases than shown..
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-7 the ack may be monitored to determine when the device is ready prior to initiating the dma. once the device is ready, no further monitoring of the ack takes place. if the amount of data to be transferred exceeds one segment, the max burst size should be set to 128 to allow for pause in the transfer that allows the ack to be monitored between segments. note that this approach will not pause at the correct location if the spare area is being accessed. examples of block erase, data read and write and status read are shown in the following timing diagrams. t wh : (wen_hi + 1) * pci_clk period shown with wen_hi = 0 t wl : (wen_lo + 1) * pci_clk periodshown with wen_lo = 0 t rl : (ren_lo + 1) * pci_clk periodshown with ren_lo = 1 figure 2: read status command_a status frame irdy trdy cs cle wen ren io pci_clk t wl t wh t rl
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-8 t wh : (wen_hi + 1) * pci_clk period shown with wen_hi = 0 t wl : (wen_lo + 1) * pci_clk periodshown with wen_lo = 0 t rh : (ren_hi + 1) * pci_clk periodshown with ren_hi = 0 t rl : (ren_lo + 1) * pci_clk periodshown with ren_lo = 0 t w : (dly + 1) * pci_clk periodwait time until ack valid figure 3: read data frame irdy trdy cs cle ale ren wen ack io pci_clk command_a add[7:0] add[16:9] add[24:17] data_1 data_2 data_n t w t wl t wl t wh t rl t rh
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-9 refer to t ab le 2 for signal descriptions. t wh : (wen_hi + 1) * pci_clk period shown with wen_hi = 0 t wl : (wen_lo + 1) * pci_clk periodshown with wen_lo = 0 figure 4: write data data_2 frame irdy trdy cs ale cle wen io pci_clk command_a add[7:0] add[16:9] add[24:17] data_1 data_n command_b t wl t wh t wh : (wen_hi + 1) * pci_clk period shown with wen_hi = 0 t wl : (wen_lo + 1) * pci_clk periodshown with wen_lo = 0 figure 5: block erase frame irdy trdy cs cle ale wen io pci_clk command_a add[16:9] add[24:17] command_b t wl t wh
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-10 3.1.2 motorola style interface the motorola style interface supports 8-bit or 16-bit devices. the following timing diagrams illustrate a 2-byte write and 2-byte read operation. the time between the falling edge of as and ds is controlled by the ds time high ?ld in the pro?e register. the time low is determined by the ds time low ?ld of the pro?e register or by the external device if ?ait for ack?is enabled. the t h (write time high) and t l (wait low) timing should be programmed to match the device according to the vendors speci?ation. the resolution is a multiple of the pci clock period. refer to the descriptions for the xio select pro?e registers. refer to t ab le 2 for signal descriptions. t h : ds_high * pci_clk period shown with ds_high = 1 t l : ds_low * pci_clk periodshown with dsack monitoring figure 6: motorola write address address + 1 data 2 data1 frame irdy trdy sel as ds r/wn addr data d sack pci_clk t h t l
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-11 refer to t ab le 2 for signal descriptions. 3.1.3 nor flash interface the nor ?sh interface supports 8-bit or 16-bit devices. the following timing diagrams illustrate write and read timings for a typical nor device. the busy signal is not shown; it should be inactive during these cycles. typically, the busy signal will be monitored before starting a transaction to the nor ?sh. the t wh (write time high) and t wl (write time low) timing should be programmed to match the device based on the ?sh vendors speci?ation. refer to the descriptions for the xio select pro?e registers. the resolution is a multiple of the pci clock period. the t r (read time, or ?ait for data? is also programmed in the pro?e bits[13:9]. t l : (ds_low +1) * pci_clk periodshown with ds_lo = 1 figure 7: motorola read address address + 1 data1 data2 frame trdy sel as ds r/wn addr data pci_clk t l internal_stb irdy r/wn
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-12 t wh : (wn_high + 1) * pci_clk period shown with wn_high = 1 t wl : (wn_low + 1) * pci_clk periodshown with wn_low = 1 figure 8: nor flash write address address + 1 data 2 data2 frame irdy trdy sel wn oen addr data pci_clk t wh t wl t r : oen_lo * pci_clk period shown with oen_lo = 3 figure 9: nor flash read address address + 1 data1 data2 frame irdy trdy sel wn oen addr data internal_stb pci_clk t r
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-13 3.1.4 ide description the ide (ata) interface supports pio mode transfer with a theoretical maximum transfer rate of 16.6 mb/s (pio-4 mode). the xio module dma is used for data transfer to and from the disk. all ide disk registers (eight command and one control) are accessible via pi. all ide disk registers are indirectly accessed via gpxio registers. figure 10 shows a block diagram of the ide interface. the ide port is multiplexed with pci, flash and motorola interface pins. there are two dedicated pins, ide_enable (xio_sel[1]) and intreq. the ide disk interrupt (intreq) is connected to a gpio signal, which is routed to the vic through gpio or any direct interrupt line. the pnx15xx series sys_rstn_out can be connected with the ide interface reset. all outputs are driven on pci_clk. all inputs are registered on pci_clk. the low and high periods of dior/diow are programmable (using sel pro?e register). all physical signals need to be isolated from pci on the board as shown in figure 11 figure 10: ide interface iso/translation logic + pullup/dn pci ad[31:16] - dd[15:0] ide cable hard disk xio_sel[1] - ide_enable intreq outputs pci_ad0 - iordy pnx15xx
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-14 data transfer operation in pio mode, data transfer to/from disk is done using read/write operations of the command and control block registers. pi/po protocol is explained in the ata-2 speci?ation. all command block registers can be programmed using direct or indirect access in the xio block. all disk registers are programmed. when the disk is ready to transfer data, dma is enabled. figure 11: isolation translation logic 74ls16245 pci ad[31:24] a1[0] a1[7] b1[0] b1[7] dd[7:0] pci ad[23:16] a2[0] a2[7] b2[0] b2[7] dd[15:8] oe_n1/2 dir1/2 xio_sel[1] - ide_enable data_dir- ad8 74ls244 ad15 ad14 ad13 ad12 ad11 ad10 ad9 ad0 da2 da1 da0 cs1 cs0 diow- dior- iordy oe1/2 vcc 1k buffer sys_rstn_out reset_n vcc 10k vcc 1k vcc 1k vcc 1k vcc 1k note the 10 k pullup required for intreq, xio_sel and the 1.0 k pullup required for diow-, dior- and iordy. vcc intreq gpio
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-15 registers all ide device registers are de?ed in the ata-2 speci?ation. these registers can be accessed directly from pi or indirectly via gpxio registers. the lower ?e bits of the gpxio address register need to be con?ured as follows: programming ide registers ide is a submodule of document title variable. it shares pci pins with other xio blocks. three xio sel pins can be con?ured for use by any xio device. each sel pin is associated with the pro?e register in the pci block. the pro?e register determines the mode of the sel pin, pulse width for control signals and memory apertures for each mode. before accessing any ide register, the appropriate pro?e register needs to be programmed. for example, if xio_sel[1] has been used for ide, the sel1_pro?e register needs to be programmed and ide needs to be enabled. at power on, the ide disk will respond in pio-0 mode only. program the appropriate register in pio-0 mode to set pio-4 mode. using sel1_pro?e register, set lo and high period of dior/diow pulses for pio-4 mode. high period in selx_pro?e register is used for the setup time of da/cs lines with dior/diow. low period in selx_pro?e register is used for the lo period of the dior/diow pulse. hold of da/cs with respect to dior/diow is always for one pci clock. recommended values for sel_we_hi and sel_we_lo for pio-0 mode are 7 and 13, respectively (assuming a 33 mhz pci clock). recommended values for sel_we_hi and sel_we_lo for pio-4 mode are 1 and 3 respectively. table 4: gpxio address con?uration address to be written register name address on ide cs1 cs0 da2 da1 da0 5?40 data register 10000 5?44 err/feature 10001 5?48 sector count 10010 5?4c sector number 10011 5?50 cylinder low 10100 5?54 cylinder high 10101 5?58 device/head 10110 5?5c status/command 10111 5?38 alternate status/device control 01110
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-16 during dma transactions the high period is used for the setup of the ?st transaction only. figure 12: register transfer/pio data transfer on ide cs0,cs1,da[2:0] dior/diow write dd[7:0]/ read dd[7:0]/ iordy t0 t1 t2 t2i t4 t5 t6z t6 ta tb tc write dd[15:0] read dd[15:0] t9 t3 trd table 5: ide timing pio timings (ata-2 spec) mode 0 mode 4 (ns) t0 cycle time (min) 600 120 t1 add valid to dior/diow setup (min) 70 25 t2 dior/diow pulse width (min) 165 70 t2i dior/diow recovery time (min) - 25 t3 diow data setup (min) 60 20 t4 diow data hold (min) 30 10 t5 dior data setup (min) 50 20 t6 dior data hold (min) 5 5 t6z dior data tristate (max) 30 30 t9 dior/diow to add, cs hold (min) 20 10 trd read data valid to iordy active (min) 0 0 ta iordy setup time (max) 35 35 tb iordy pulse width (max) 1250 1250 tc iordy assertion to release (max) - 5
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-17 3.2 pci interrupt enable register the pci_int a function is not implemented within the pci module. figure 13: timings on ide bus pci_clk cs0.cs1,da[2:0] diow-/dior- write dd[7:0]/: read dd[7:0]/ iordy-pullup 30 ns t1 - 30 ns t2 - 90ns t3 - 30ns t4 - 30ns t9 - 30ns ta - 60ns t0 - 150 nsec t2i - 60ns write dd[15:0]/: read dd[15:0]/ note: all outputs driven by pci-clk figure 14: ide transaction, flow controlled by device iordy pci_clk addr diow/dior write dd[7: read dd[7:0] iordy-pullup
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-18 4. application notes 4.1 dtl interface the dtl side of the pci module, figure 1 , consists of a single initiator and 4 targets. it supports both big and little-endian systems. features: dedicated port for mmio register access dedicated port for direct access to xio devices dedicated port for pci memory space second pci port which may be con?ured to access pci memory or io space each port may be con?ured for posted or non-posted writes. bursting to internal mmio register space is not supported. the 2 pci targets support ?etry?on pci for reads and non-posted single writes. 4.2 system memory bus interface, the mtl bus to optimize pci-to-system memory throughput in the pnx15xx series system, a direct path is provided between pci and the system memory bus using the mtl interface. features: for pci burst reads, speculative read of user-selectable number of words is done from the memory. two read and two write channels continuous pci write/read bursts can be sustained (contingent on availability of data on the dvp memory bus). the memory interface has two registers that allow the interface to be tuned for optimum performance. a slave tuning register allows the user to select how much data will be prefetched from memory during reads. for mem_read commands, anywhere from 2 to 32 32-bit words may be selected. for mem_read_line commands, one cache line will be prefetched. and for mem_read_multiple, anywhere from 8 to 1024 32-bit words may be prefetched. a threshold is used to determine when additional data should be requested. this must be set to a value smaller then the smallest of the 3 prefetch sizes of the various read memory command types. note that the cache line size must be set to a non-zero value before using cache line read commands. the dma read channel also has a prefetch size and threshold register. improper settings of these registers combined with improper command type can result in an external master being starved for data. an example of this is when 2 masters are both attempting to do reads from the pci.
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-19 the ?st is doing large burst with the memory-read command and the other single or burst reads. since the memory read command is intended for relatively short bursts, only a small amount of data is prefetched. when it is nearly all consumed, additional data will be prefetched. while the data is being prefetched, the rule the additional data phases must complete within 8 clocks may come into play. this results in a disconnect on the ?st master. when the second master gets the gnt and attempts a read, it will be retried since the internal state machine is busy with the prefetch of data requested by the ?st master. now the ?st returns for a continuation of its read. when data runs low again, additional data will be prefetched, during which another disconnect occurs. this cycle may repeat until the ?st master has completed its entire burst. 4.3 xio interface the xio interface uses a part of the pci interface and some additional signals to interface with external flash (nand and nor types), nor-rom, ide and motorola devices. this function ?teals?a pci cycle and runs an xio transfer using part of the pci bus before giving control back to pci. the xio port may be accessed at any time after the con?uration registers have been initialized. up to ?e pro?es may be enabled at one time. each one requires a chip select. when 64 mb addressing is required, an extra pin (xio_a[25]) is required with nor ?sh and motorola style devices. flash pro?es have a dedicated ack pin to allow pci transactions to continue while the device is busy. 4.3.1 motorola interface in this xio mode, any 8-bit or 16 bit motorola 68360 type external slave can be addressed. for details about connecting a motorola device to a pci interface, please refer to t ab le 2 . even though the motorola interface is an asynchronous interface, internal timings are generated in multiples of pci clock. for programming to do motorola cycles, please refer to xio sel_x pro?e registers. for writes, data-strobe (ds) assertion time is made programmable by using sel0_we_hi ?ld. there is an option to use the acknowledge from the device dsack, or to have a ?ed wait time before probing for read-data and removing ds for write-data. 4.3.2 nand-flash interface a ?xible interface is provided to interface to a nand-flash. there are two registers that de?e the type of cycle that will be performed. the read and write strobes can be programmed independently with a high timer from one to four pci clocks. a cycle may contain 0, 1, or 2 commands and 0, 1, 2, 3 or 4 address phases with or without data. refer to section 3.1.1 nand-flash interf ace oper ation for information on how to use this interface. 4.3.3 nor flash interface in this xio mode, any 8-bit or 16-bit nor ?sh can be addressed. up to 64 mb may be addressed. the ds timing is programmable as is the wn timing. the user has the option of monitoring the r/bn signal from the ?sh or using a ?ed response for the ds low timing.
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-20 4.3.4 ide interface in this xio mode, an ide disk drive can be addressed. only pio mode is supported. the internal dma engine can be programmed to perform data transfer to and from the ide once the disk drives registers have been programmed. the dior and diow strobe high and low times are programmable. refer to section 3.1.4 ide descr iption for more details. the ide interface is internally grouped with 16bit xio devices. this restricts the software in direct and indirect ide register access to using 16 or 32 bit opcodes for writes and reads. these are mapped to a single write or read on accessing the ide drive. 4.4 pci endian support the pci module supports both big-endian and little-endian systems. the global system endian mode signal is used to determine which endian mode is in use. 4.5 general notes the cache line size register (pci con?uration register c) should be initialized to a non-zero value larger than the ?lv_threshold?(slave dtl tuning register) if using cache line read commands in the system. see note on recommended slv_threshold setting in the register description. 5. register descriptions the following section describes the registers in the document title variable block. the pci con?uration registers and the memory mapped io registers are included.
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-21 5.1 register summary table 6: pci-xio register summary bit symbol description 0x0000?x000c reserved 0x04 0010 pci_setup pci setup register 0x04 0014 pci_control pci control register 0x04 0018 pci_base1_lo internal view of external pci bottom address, 1st aperture 0x04 001c pci_base1_hi internal view of external pci top address, 1st aperture 0x04 0020 pci_base2_lo internal view of external pci bottom address, 2nd aperture 0x04 0024 pci_base2_hi internal view of external pci top address, 2nd aperture 0x04 0028 read_lifetime length of time data is held exclusively for requesting agent. 0x04 002c gppm_addr general purpose pci master cycle address register 0x04 0030 gppm_wdata general purpose pci master cycle write data register 0x04 0034 gppm_rdata general purpose pci master cycle read data register 0x04 0038 gppm_ctrl general purpose pci master cycle control register 0x04 003c unlock_register unlock pci_setup, class code, subsystem_ids 0x04 0040 device/vendorid image of device id and vendor id (con? reg 00) 0x04 0044 con?_cmd_stat image of con?uration command and status register (con? reg 04) 0x04 0048 class code/rev id image of class code and revision id (con? reg 08) 0x04 004c latency timer image of latency timer, cache line size (con? reg 0c) 0x04 0050 base10 image of con?uration base address10 (con? reg 10) 0x04 0054 base14 image of con?uration base address14 (con? reg 14) 0x04 0058 base18 image of con?uration base address18 (con? reg 18) 0x04 005c?068 reserved 0x04 006c subsystem ids subsystem id, subsystem vendor id (con? reg 2c) 0x04 0070 reserved 0x04 0074 cap_pointer image of capabilities pointer (con? reg 34) 0x04 0078 reserved 0x04 007c con?_misc image of interrupt line, and interrupt line registers (con? reg 3c) 0x04 0080 pmc power management capabilities (con? reg 40) 0x04 0084 pwr_state power management control (con? reg 44) 0x04 0088 pci_io pci io properties 0x04 008c slv_tuning slave dtl tuning 0x04 0090 dma_tuning dma dtl tuning 0x04 0094?7fc reserved 0x04 0800 dma_eaddr pci address for dma transaction 0x04 0804 dma_iaddr internal address for dma transaction 0x04 0808 dma_length dma length in words 0x04 080c dma_ctrl dma control
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-22 remark: the pci configuration registers have no base address in the pnx15xx series. 0x04 0810 xio_ctrl xio misc control 0x04 0814 xio_sel0_prof xio sel0 pro?e 0x04 0818 xio_sel1_prof xio sel1 pro?e 0x04 081c xio_sel2_prof xio sel2 pro?e 0x04 0820 gpxio_addr indirect general purpose xio address 0x04 0824 gpxio_wdata indirect general purpose xio write data 0x04 0828 gpxio_rdata indirect general purpose xio read data 0x04 082c gpxio_ctrl indirect general purpose xio control 0x04 0830 nand_ctrls nand-flash pro?e controls 0x04 0834 xio_sel3_prof xio sel3 pro?e 0x04 0838 xio_sel4_prof xio sel4 pro?e 0x04 083c?fac reserved 0x04 0fb0 gpxio_status gpxio interrupt status 0x04 0fb4 gpxio_int_mask gpxio interrupt enable 0x04 0fb8 gpxio_int_clr gpxio interrupt clear 0x04 0fbc gpxio_int_set gpxio interrupt set 0x04 0fc0 gppm_status gppm interrupt status 0x04 0fc4 gppm_int_mask gppm interrupt enable 0x04 0fc8 gppm_int_clr gppm interrupt clear 0x04 0fcc gppm_int_set gppm interrupt set 0x04 0fd0 dma_status dma interrupt status 0x04 0fd4 dma_int_mask dma interrupt enable 0x04 0fd8 dma_int_clr dma interrupt clear 0x04 0fdc dma_int_set dma interrupt set 0x04 0fe0 pci_status pci interrupt status 0x04 0fe4 pci_int_mask pci interrupt enable 0x04 0fe8 pci_int_clr pci interrupt clear 0x04 0fec pci_int_set pci interrupt set 0x04 0ff0?ff8 reserved 0x04 0ffc module_id module id table 6: pci-xio register summary ?ontinued bit symbol description table 7: pci con?uration register summary bit symbol description 0x0000 device / vendor id device id and vendor id 0x0004 command / status command and status register 0x0008 class code/rev id class code to be speci?d appropriate for the application. this will be implemented as a parameter. the rev id will initially be 0.
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-23 the following table is a summary of all the registers in this module. 0x000c latency timer/ cache line size latency timer, cache line size. 0x0010 base address 10 base address, memory 0x0014 base address 14 base address, memory ?mmio 0x0018 base address 18 base address, memory ?xio 0x001 0028 reserved 0x002c subsystem id subsystem id and subsystem vendor id 0x0030 reserved 0x0034 capability pointer capabilities pointer register 0x0038 reserved 0x003c intr interrupt line, interrupt pin, min_gnt, max_lat 0x0040 pmc power management capability 0x0044 pwr_state power management control table 7: pci con?uration register summary ?ontinued bit symbol description table 8: registers description bit symbol acces s value description pci control registers this register must be initialized before any pci cycles will be entertained. the boot loader is expected to load the values at boot time. write once by boot loader, otherwise read only. because this register is ?ritten once the bit ?lds are designated ?/w1.?an unlock is available to update this register if necessary. a write of ?a?to bits [7:0] of the unlock_setup register will allow one additional write to the setup register before locking again offset 0x04 0010 pci setup 31 reserved r 0 30 dis_reqgnt r/w1 0 disable use of req/gnt when using internal arbiter. these pins may be released for other uses when using an internal arbiter and no external pci masters are used in the system. 29 dis_reqgnt_a r/w1 0 disable use of req_a/gnt_a when using internal arbiter. these pins are not used when using an external harborer. 28 dis_reqgnt_b r/w1 0 disable use of req_b/gnt_b when using internal arbiter. these pins are not used when using an external arbiter. 27 d2_support r/w1 1 support for d2 power state 26 d1_support r/w1 1 support for d1 power state 25 reserved r/w1 0 24 en_ta r/w1 0 terminate restricted access attempt with target abort (otherwise, ignore writes, return 0 on read). 23 en_pci2mmi r/w1 1 enable memory hwy interface. 22 en_xio r/w1 1 enable xio functionality. 21 base18_prefetchable r/w1 0 pci base address 18 is a prefetchable memory aperture.
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-24 20:18 base18_siz r/w1 011 the size of aperture located by pci cfg base18 is: 011 = 16 mb 100 = 32 mb 101 = 64 mb 110 = 128 mb this aperture is used as the xio aperture in the pnx15xx series. note: if expanding to 128 mb, the default setting of base18 address will overlap with the default base14 address. to avoid an address con?ct, the base18 address or the base14 address should be relocated before setting the base18_siz. 17 en_base18 r/w1 1 enable 3rd aperture, pci base address 18. the pnx15xx series will always use this aperture. 16 base14_prefetchable r/w1 0 pci base address 14 is a non-prefetchable memory aperture. 15 reserved r 0 14:12 base14_siz r/w1 000 the size of aperture located by pci cfg base 14 is 000 = 2 mb. this aperture is used as the mmio aperture in the pnx15xx series. 11 en_base14 r/w1 1 enable 2nd aperture, pci base address 14. the pnx15xx series will always use this aperture. 10 base10_prefetchable r/w1 1 pci base address 10 is a prefetchable memory aperture. 9:7 base10_siz r/w1 100 the size of aperture located by pci cfg base 10 is: 011 = 16 mb 100 = 32 mb 101 = 64 mb 110 = 128 mb this aperture is used as the dram aperture in the pnx15xx series. 6:2 reserved 1 en_con?_manag r/w1 1 enable con?uration management. 0 en_pci_arb r/w1 0 enable internal pci system arbitration. offset 0x04 0014 pci control 31:17 reserved r 0 16 dis_swapper2targ r/w 0 0 = enable byte swapping in big endian mode from dcs to pci path. 1 = disable byte swapping in big endian mode from dcs to pci path. 15 dis_swapper2intreg r/w 0 0 = enable byte swapping in big endian mode from pci to pci mmio registers. 1 = disable byte swapping in big endian mode from pci to pci mmio registers. 14 dis_swapper2dtlinit r/w 0 0 = enable byte swapping in big endian mode from pci to dcs. 1 = disable byte swapping in big endian mode from pci to dcs. 13 regs_wr_post_en r/w 0 enable write posting to internal pci registers. 12 xio_wr_post_en r/w 0 enable write posting to xio address range. 11 pci2_wr_post_en r/w 0 enable write posting to pci_base2 address range. table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-25 10 pci1_wr_post_en r/w 0 enable write posting to pci_base1 address range. 9 en_serr_seen r/w 0 enable monitoring of the serr pin. 8:7 reserved r 0 6 en_base10_spec_rd r/w 1 read ahead to optimize pci read latency to base 10. 5 en_base14_spec_rd r/w 0 read ahead to optimize pci read latency to base 14. 4 en_base18_spec_rd r/w 0 read ahead to optimize pci read latency to base 18. 3 disable_subword2_10 r/w 0 disable subword access to/from base10 aperture. 2 disable_subword2_14 r/w 1 disable subword access to/from base14 aperture. 1 disable_subword2_18 r/w 1 disable subword access to/from base18 aperture. 0 en_retry_timer r/w 1 enables timer for 16 tic rule enforcer. this bit does not affect access to the xio aperture. offset 0x04 0018 pci_base1_lo 31:21 pci_base1_lo r/w 0 for internal address decoding: low bar of ?st aperture for external pci access. this register affects the decode and routing of the bus controllers. it should not be relied on as stable for 10 clocks after writing. it is recommended that the pci_base1_lo be initialized before the pci_base1_hi to avoid a potentially large segment of address space being temporarily allocated to pci space. 20:0 reserved r 0 offset 0x04 001c pci_base1_hi 31:21 pci_base1_hi r/w 0 for internal address decoding: high bar of ?st aperture for external pci access (up to but not including). this register affects the decode and routing of the bus controllers. it should not be relied on as stable for 10 clocks after writing. it is recommended the pci_base1_lo be initialized before the pci_base1_hi to avoid a potentially large segment of address space being temporarily allocated to pci space. 20:0 reserved r 0 offset 0x04 0020 pci_base2_lo 31:21 pci_base2_lo r/w 0 for internal address decoding: low bar of second aperture for external pci access. this register affects the decode and routing of the bus controllers. it should not be relied on as stable for 10 clocks after writing. it is recommended the pci_base2_lo be initialized before the pci_base2_hi to avoid a potentially large segment of address space being temporarily allocated to pci space. the pci_base2 aperture may be declared as a internal view of pci io space or as pci memory space. see pci_io register for more information. 20:0 reserved r 0 table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-26 offset 0x04 0024 pci_base2_hi 31:21 pci_base2_hi r/w 0 for internal address decoding: high bar of second aperture for external pci access (up to but not including). this register affects the decode and routing of the bus controllers. it should not be relied on as stable for 10 clocks after writing. it is recommended the pci_base2_lo be initialized before the pci_base2_hi to avoid a potentially large segment of address space being temporarily allocated to pci space. the pci_base2 aperture may be declared as a internal view of pci io space or as pci memory space. see pci_io register for more information. 20:0 reserved r 0 offset 0x04 0028 read data lifetime timer 31:16 unused - 15:0 read_lifetime r/w 8000 this register is the amount of time (in pci clocks) the pci will hold a piece of data exclusively for an external pci master. the timer is initiated when the pci can not complete the requested read in 16 clock cycles and issues a retry. offset 0x04 002c general purpose pci master (gppm) address 31:0 gppm_addr r/w 0 this register will be written with the address for the single data phase cycle to be issued on the pci bus. it will accept only 32-bit writes. when issuing type 0 con?uration transactions, the device number (bits [15:11]) is expanded to bits [31:11] on the pci bus as de?ed in the pci 2.2 spec. offset 0x04 0030 general purpose pci master (gppm) write data 31:0 gppm_wdata r/w 0 this register will be written with the data for the single data phase cycle to be issued on the pci bus. this register will accept any size write. offset 0x04 0034 general purpose pci master (gppm) read data 31:0 gppm_rdata r 0 this register will hold data from the selected target after completion of the read. offset 0x04 0038 general purpose pci master (gppm) control 31:11 reserved r 0 10 gppm_done r 0 1 = cycle has completed. this bit can also be viewed in the gppm_status register. write to register 0x40fc8 to clear. 9 init_pci_cycle r/w 0 1 = initiate a pci single data phase transaction on the pci bus with address ?ppm_addr?and data ?ppm_data. 8 reserved r 0 7:4 gppm_cmd r/w 0 command to be used with pci cycle. acceptable commands to use in the command ?ld include io read, io write, memory read, memory write, con?uration read and interrupt acknowledge. if con?uration management is enabled, con?uration write may be used. 3:0 gppm_ben r/w 0 byte enables to be used with pci cycle offset 0x04 003c unlock register 31:16 reserved r 0 table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-27 15:8 unlock_ssid w 0 writing a ?xca?to this ?ld will unlock the ?ubsystem_id?and ?ubsystem_vendor?registers. a writer to the subsystem_id/ subsystemvendor?register will lock the register again. 7:0 unlock_setup w 0 writing a ?xca?to this ?ld will unlock the ?lasscode? ?ax_latency? ?in_gnt?and ?ci_setup?registers. a write to the ?ci_setup?register to lock registers again. offset 0x04 0040 image of device id and vendor id 31:16 device_id r 0x5405 pci con?uration device id 15:0 vendor_id r 0x1131 pci con?uration vendor id offset 0x04 0044 image of command/status 31:16 status r 0x0290 pci con?uration status register 15:0 command r/w* 0x0000 pci con?uration command register. *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. refer to con?uration register 4 for details on which bits are implemented and controllable. offset 0x04 0048 image of class code/revision id 31:8 class code r/w* 048000 pci con?uration class code. *write-once/read-only 7:0 revision id r 1 pci con?uration revision id offset 0x04 004c image of latency timer/cache line size 31:24 bist r 0 pci con?uration bist 23:16 header type r 0 pci con?uration header type 15:8 latency timer r/w* 0 pci con?uration latency timer. *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. 7:0 cache line size r/w* 0 pci con?uration cache line size. *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. offset 0x04 0050 base address 10 image 31:21 base address 10 r/w* 0 pci con?uration base address for dram. this register affects the decode and routing of the bus controllers. it should not be relied on as stable for 10 clocks after writing. *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. 20:4 reserved r 0 3 prefetchable r cfg* *value is determined at boot time by pci_setup register. 2:0 type r 0 indicates type 0 memory space (locatable anywhere in 32-bit address space). offset 0x04 0054 base address 14 image 31:4 base address 14 r/w* 1be00000 pci con?uration base address for mmio. this register affects the decode and routing of the bus controllers. it should not be relied on as stable for 10 clocks after writing. *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-28 3 prefetchable r cfg* *value is determined at boot time by pci_setup register. 2:0 type r 0 indicates type 0 memory space (locatable anywhere in 32-bit address space). offset 0x04 0058 base address 18 image 31:4 base address 18 r/w* 1c00000 pci con?uration base address for xio. this register affects the decode and routing of the bus controllers. it should not be relied on as stable for 10 clocks after writing. *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. 3 prefetchable r cfg* *value is determined at boot time by pci_setup register. 2:0 type r 0 indicates pci ?ype 0?memory space (locatable anywhere in 32-bit address space). offset 0x04 006c subsystem id/subsystem vendor id write port this register must be initialized before any pci cycles will be entertained. the boot loader is expected to load the values at boot time. this register is a write-once/read-only register (r/w1). 31:16 subsystem id r/w1 0 this is the write port for the subsystem id (pci con? 2c). 15:0 subsystem vendor id r/w1 0 this is the write port for the subsystem vendor id (pci con? 2c). offset 0x04 0074 image of con?uration reg 34 31:8 reserved r 0 7:0 cap_ptr r 40 capabilities pointer offset 0x04 007c image of con?uration reg 3c 31:24 max_lat r/w1 0x18 max latency 23:16 min_gnt r/w1 0x09 minimum grant 15:8 interrupt pin r 0x01 interrupt pin information 7:0 interrupt line r/w* 0x00 this register conveys interrupt line routing information. *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. offset 0x04 0080 image of con?uration reg 40 31:27 reserved r 00000 26 d2_support r cfg* 1 = device supports d2 power management state. *value is determined by pci_setup register. 25 d1_support r cfg* 1 = device supports d1 power management state. *value is determined by pci_setup register. 24:19 reserved r 0 18:16 version r 010 indicates compliance with version 1.1 of pm. 15:8 next item pointer r 00 there are no other extended capabilities. 7:0 cap_id r 01 indicates this is power management data structure. offset 0x04 0084 image of con?uration reg 44 31:1 reserved r 0 1:0 pwr_state r/w* 0 power state *this register is read/write if con?uration management is enabled (pci_setup[1]). if not enabled, it is read only. table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-29 offset 0x04 0088 pci_io 31:24 upper_io3_addr r/w 0 bits [31:24] of io address during pci io transactions. 23:16 upper_io2_addr r/w 0 bits [23:16] of io address during pci io transactions. 15:3 reserved r 0 2 use_io3_addr r/w 0 use ?pper_io3_addr as the upper address for pci io transactions. 1 use_io2_addr r/w 0 use ?pper_io3_addr?and ?pper_io2_addr?as the upper address for pci io transactions. 0 use_pcibase2_as_io r/w 0 1: pci_base2 will forward pci2 dtl transactions to pci bus as io transactions. the address will unchanged or modi?d with an alternate upper addresses selected above. 0: pci_base2 will forward pci2 dtl transactions to pci bus as memory transactions with unchanged address. offset 0x04 008c slave dtl tuning 31:24 reserved r 0 20:16 slv_memrd_fetch r/w 111 pci slave dtl read block size for memory read command. default value is 8 32-bit words. maximum is 64 32-bit words. 11:8 slv_threshold r/w 10 threshold (amount of data not consumed from previous read request) for when pci slave dtl requests more read data when responding to memory read command. this must be set to a value less than the smallest of slv_memrd_fetch, cache line size or read_block_siz. default is 3 32-bit words. maximum value is 32 32- bit words. 7:3 reserved r 0 2:0 slv_mrmul_fetch r/w 001 encoded pci slave dtl read block size for memory read multiple command siz : read_block_siz 000: 8 bytes 001: 16 bytes 010: 32 bytes 011: 64 bytes 100: 128 bytes 101: 256 bytes 110: 512 bytes 111: 1024 bytes offset 0x04 0090 dma dtl tuning 31:16 reserved r 0 15:8 dma_threshold r/w 0x1b threshold for when dma dtl requests more read data when initial fetch is less than total dma length. 7:3 reserved r 0 table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-30 2:0 dma_fetch r/w 010 encoded dma dtl read block size siz read_block_siz 000: 8 bytes 001: 16 bytes 010: 32 bytes 011: 64 bytes 100: 128 bytes 101: 256 bytes 110: 512 bytes 111: 1024 bytes offset 0x04 0094?7fc reserved offset 0x04 0800 dma pci address this register will accept only word writes. 31:0 dma_eaddr r/w 1c00_00 00 this is the external starting address for the dma engine. it is used for dma transfers over pci and xio. bit 0 and 1 are not used because all dma transfers are word aligned. offset 0x04 0804 dma internal address this register will accept only word writes. 31:0 dma_iaddr r/w 0010_00 00 this is the internal read source/ write destination address in sdram. offset 0x04 0808 dma transfer size this register will accept any size writes. 31:16 reserved r/w 0 15:0 dma_length r/w 800 this is the length of the dma transfer (number of 4-byte words). offset 0x04 080c dma controls this register will accept any size writes. 31:11 reserved r 0 10 single_data_phase r/w 0 1 = limit dma to single data phase transactions. this overrides ?ax_burst_size. 0 = use max_burst_size to determine burst size. 9 snd2xio r/w 0 0 = dma will target pci. 1 = dma will target xio. 8 ?_addr r/w 0 0 = dma will use linear address. 1 = dma will use a ?ed address. table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-31 7:5 max_burst_size r/w 0 pci transaction will be split into multiple transactions. max size: 000 = 8 data phase 001 = 16 data phase 010 = 32 data phase 011 = 64 data phase 100 = 128 data phase 101 = 256 data phase 110 = 512 data phase 111 = no restriction in transfer length 4 init_dma r/w 0 initiate dma transaction. this bit is cleared by the dma engine when it begins its operation. 3:0 cmd_type r/w 0 command to be used for dma. this ?ld is restricted to memory type or io type commands as de?ed in the pci 2.2 spec. offset 0x04 0810 xio control register 31:2 reserved r 0 1 xio_ack r live xio_ack status bit. 0 reserved r 0 offset 0x04 0814 xio sel0 pro?e this register sets up the pro?e of the xio select 0 line. all times are in reference to pci clocks. 31:25 reserved r 0 24 misc_ctrl r/w 0 68360: 1 synchronous dsack; 0 asynchronous dsack. nor: not used nand: not used ide: not used 23 en_16bit_xio r/w 0 0 = 8 bit xio device 1 = 16 bit xio device 22 sel0_use_ack r/w 0 0 = fixed wait state 1 = wait for ack not used for ide. 21:18 sel0_we_hi r/w 0 68360: ds time high. nor: wn time high nand: ren pro?e, [19:18] low time; [21:20] high time ide: dior and diow high time 17:14 sel0_we_lo r/w 0 68360: not used. nor: wn time low nand: wen pro?e, [15:14] low time; [17:16] high time ide: dior and diow low time 13:9 sel0_wait r/w 0 68360: ds time low if using ?ed timing. nor: oen time low if not using ack. nand: delay between address and data phase if not using ack, delay until monitoring ack. ide: not used. 8:5 sel0_offset r/w 0 starting address offset from start address of xio aperture, in 8m increments. this ?ld must be naturally aligned with the size of the pro?e. table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-32 4:3 sel0_type r/w 0 device type selected: 00 = 68360 type device 01 = nor flash 10 = nand-flash 11 = ide 2:1 sel0_siz r/w 0 amount of address space allocated to sel0: 00 = 8m 01 = 16m 10 = 32m 11 = 64m 0 en_sel0 r/w 0 1 = enable sel0 pro?e. offset 0x04 0818 xio sel1 pro?e this register sets up the pro?e of the xio select 1 line. all times are in reference to pci clocks. 31:25 reserved r 0 24 misc_ctrl r/w 0 68360: 1 synchronous dsack; 0 asynchronous dsack. nor: not used nand: not used ide: not used 23 en_16bit_xio r/w 0 0 = 8 bit xio device 1 = 16 bit xio device 22 sel1_use_ack r/w 0 1 = wait for ack 0 = ?ed wait state. not used for ide. 21:18 sel1_we_hi r/w 0 63860: time high. nor: wn time high nand: ren pro?e, [19:18] low time; [21:20] high time ide: dior and diow high time 17:14 sel1_we_lo r/w 0 63860: not used. nor: wn time low nand: wen pro?e, [15:14] low time; [17:16] high time ide: dior and diow low time 13:9 sel1_wait r/w 0 63860: ds time low if using ?ed timing. nor: oen time low if not using ack. nand: delay between address and data phase if not using ack, delay until monitoring ack. ide: not used. 8:5 sel1_offset r/w 0 address offset form start address of xio aperture, in 8m increments. this ?ld must be naturally aligned with the size of the pro?e. 4:3 sel1_type r/w 0 sel1 is con?ured as: 00 = 68360 type device 01 = nor flash 10 = nand-flash 11 = ide table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-33 2:1 sel1_siz r/w 0 amount of address space allocated to sel1: 00 = 8m 01 = 16m 10 = 32m 11 = 64m 0 en_sel1 r/w 0 enable sel1 pro?e. offset 0x04 081c xio sel2 pro?e this register sets up the pro?e of the xio select 2 line. all times are in reference to pci clocks. 31:25 reserved r 0 24 misc_ctrl r/w 0 68360: 1 synchronous dsack; 0 asynchronous dsack. nor: not used nand: not used ide: not used 23 en_16bit_xio r/w 0 0 = 8 bit xio device 1 = 16 bit xio device 22 sel2_use_ack r/w 0 0 = fixed wait state. 1 = wait for ack not used for ide 21:18 sel2_we_hi r/w 0 68360: ds time high. nor: wn time high nand: ren pro?e, [19:18] low time; [21:20] high time ide: dior and diow high time 17:14 sel2_we_lo r/w 0 63860: not used. nor: wn time low nand: wen pro?e, [15:14] low time; [17:16] high time ide: dior and diow low time 13:9 sel2_wait r/w 0 68360: ds time low if using ?ed timing. nor: oen time low if not using ack. nand: delay between address and data phase if not using ack, delay until monitoring ack. ide: not used. 8:5 sel2_offset r/w 0 address offset form start address of xio aperture, in 8m increments. this ?ld must be naturally aligned with the size of the pro?e. 4:3 sel2_type r/w sel2 is con?ured as: 00 = 68360 type device 01 = nor flash 10 = nand-flash 11 = ide 2:1 sel2_siz r/w 0 amount of address space allocated to sel2: 00 = 8m 01 = 16m 10 = 32m 11 = 64m 0 en_sel2 r/w 0 enable sel2 pro?e. table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-34 offset 0x04 0820 gpxio_address 31:0 gpxio_addr r/w 0 general purpose xio cycle address. this register sets the address for an indirect read or write to/from xio address space. only 4 byte writes are allowed in this register. the values programmed for bits 0 and 1 are not used by the xio module. refer to gpxio_ben. offset 0x04 0824 gpxio_write_data 31:0 gpxio_wdata r/w 0 general purpose xio cycle data. this register is programmed with data for a write cycle. offset 0x04 0828 gpxio_read_data 31:0 gpxio_rdata r 0 general purpose xio cycle data. this register contains the data of a read cycle after completion. offset 0x04 082c gpxio_ctrl this register controls the type of access to xio and provides status. 31:10 reserved r 0 9 gpxio_cyc_pending r 0 1 = gpxio transaction on xio is pending. 0 = gpxio has completed or not yet started. 8 gpxio_done r 0 general purpose xio cycle complete. this bit is cleared by writing 1 to bit 6 or 7. it will also be cleared by writing to the gpxio interrupt clear register. 7 clr_gpxio_done w 0 1 = clear ?pxio_done. 6 gpxio_init r/w 0 1 = initiate a transaction on xio. the type of transaction will match the pro?e of the selected aperture. this bit gets cleared if the cycle has been initiated. this bit clears bit 8 if set. 5 reserved r 0 4 gpxio_rd r/w 0 1 = read command on xio 0 = write command on xio 3:0 gpxio_ben r/w 0 active low byte enables to be used on the indirect xio cycle. these are used to determine how many bytes to access and the lower two address bits for use in ?pxio_addr? offset 0x04 0830 nand-flash controls 31:22 reserved 21:16 nand_ctrls r/w 17 this ?ld controls the type of nand-flash access cycle. the bits are de?ed as follows: [21]: 1= 64-mb device support; 0 = 32 mb and smaller device support [20]: 1 = include data in access cycle; 0 access does not include data phase(s) [19:18] = no. of commands to be used in nand-flash access [17:16] = no. of address phases to be used in nand-flash access. for 64-mb devices, 11 provide four address phases and 10 provide three address phases. 15:8 command_b r/w 0 this is the second command for nand-flash when two commands are required to complete a cycle. 7:0 command_a r/w 0 this is the command type to be used with nand-flash cycles when one or more commands are required to complete a cycle. table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-35 offset 0x04 0834 xio sel3 pro?e this register sets up the pro?e of the xio select 3 line. all times are in reference to pci clocks. 31:25 reserved r 0 24 misc_ctrl r/w 0 68360: 1 synchronous dsack; 0 asynchronous dsack. nor: not used nand: not used ide: not used 23 en_16bit_xio r/w 0 0 = 8 bit xio device 1 = 16 bit xio device 22 sel3_use_ack r/w 0 0 = fixed wait state 1 = wait for ack not used for ide. 21:18 sel3_we_hi r/w 0 68360: ds time high. nor: wn time high nand: ren pro?e, [19:18] low time; [21:20] high time ide: dior and diow high time 17:14 sel3_we_lo r/w 0 68360: not used. nor: wn time low nand: wen pro?e, [15:14] low time; [17:16] high time ide: dior and diow low time 13:9 sel3_wait r/w 0 68360: ds time low if using ?ed timing. nor: oen time low if not using ack. nand: delay between address and data phase if not using ack, delay until monitoring ack. ide: not used. 8:5 sel3_offset r/w 0 starting address offset from start address of xio aperture, in 8m increments. this ?ld must be naturally aligned with the size of the pro?e. 4:3 sel3_type r/w 0 device type selected: 00 = 68360 type device 01 = nor flash 10 = nand flash 11 = ide 2:1 sel3_siz r/w 0 amount of address space allocated to sel3: 00 = 8m 01 = 16m 10 = 32m 11 = 64m 0 en_sel3 r/w 0 1 = enable sel3 pro?e offset 0x04 0838 xio sel4 pro?e this register sets up the pro?e of the xio select 4line. all times are in reference to pci clocks. 31:25 reserved r 0 24 misc_ctrl r/w 0 68360: 1 synchronous dsack; 0 asynchronous dsack. nor: not used nand: not used ide: not used table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-36 23 en_16bit_xio r/w 0 0 = 8 bit xio device 1 = 16 bit xio device 22 sel4_use_ack r/w 0 0 = fixed wait state 1 = wait for ack not used for ide. 21:18 sel4_we_hi r/w 0 68360: ds time high. nor: wn time high nand: ren pro?e, [19:18] low time; [21:20] high time ide: dior and diow high time 17:14 sel4_we_lo r/w 0 68360: not used. nor: wn time low nand: wen pro?e, [15:14] low time; [17:16] high time ide: dior and diow low time 13:9 sel4_wait r/w 0 68360: ds time low if using ?ed timing. nor: oen time low if not using ack. nand: delay between address and data phase if not using ack, delay until monitoring ack. ide: not used. 8:5 sel4_offset r/w 0 starting address offset from start address of xio aperture, in 8m increments. this ?ld must be naturally aligned with the size of the pro?e. 4:3 sel4_type r/w 0 device type selected: 00 = 68360 type device 01 = nor flash 10 = nand flash 11 = ide 2:1 sel4_siz r/w 0 amount of address space allocated to sel4: 00 = 8m 01 = 16m 10 = 32m 11 = 64m 0 en_sel4 r/w 0 1 = enable sel4 pro?e offset 0x04 0fb0 gpxio interrupt status 31:15 reserved r 0 14 gpxio_xio_ack_done r 0 rising edge of xio_ack has been observed 13 gpxio_done r 0 gpxio transaction completed 12:10 reserved r 0 9 gpxio_err r 0 non-supported gpxio command attempted or not enabled 8:3 reserved r 0 2 gpxio_r_mabort r 0 gpxio received master abort 1:0 reserved r 0 offset 0x04 0fb4 gpxio interrupt enable 31:15 reserved r 0 table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-37 14 en_int_gpxio_xio_ack_d one r 0 enable interrupt on rising edge of xio_ack has been observed 13 en_int_gpxio_done r 0 enable interrupt on gpxio transaction completed 12:10 reserved r 0 9 en_int_gpxio_err r 0 enable interrupt on non-supported gpxio command attempted or not enabled 8:3 reserved r 0 2 en_int_gpxio_r_mabort r 0 enable interrupt on gpxio received master abort 1:0 reserved r 0 offset 0x04 0fb8 gpxio interrupt clear 31:15 reserved r 0 14 clr_gpxio_xio_ack_done r 0 clear rising edge of xio_ack has been observed 13 clr_gpxio_done r 0 clear gpxio transaction completed 12:10 reserved r 0 9 clr_gpxio_err r 0 clear non-supported gpxio command attempted or not enabled 8:3 reserved r 0 2 clr_gpxio_r_mabort r 0 clear gpxio received master abort 1:0 reserved r 0 offset 0x04 0fbc gpxio interrupt set 31:15 reserved r 0 14 set_gpxio_xio_ack_done r 0 set rising edge of xio_ack has been observed 13 set_gpxio_done r 0 set gpxio transaction completed 12:10 reserved r 0 9 set_gpxio_err r 0 set non-supported gpxio command attempted or not enabled 8:3 reserved r 0 2 set_gpxio_r_mabort r 0 set gpxio received master abort 1:0 reserved r 0 offset 0x04 0fc0 gppm interrupt status 31:11 reserved r 0 10 gppm_done r 0 gppm transaction completed 9 gppm_err r 0 non-supported gppm command attempted or not enabled 8:6 reserved r 0 5 gppm_mstr_parity_err r 0 gppm master set or observed parity error (perr) 4 gppm_err_parity r 0 gppm detected parity error (perr) 3 reserved r 0 2 gppm_r_mabort r 0 gppm received master abort 1 gppm_r_tabor r 0 gppm received target abort 0 reserved r 0 table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-38 offset 0x04 0fc4 gppm interrupt enable 31:11 reserved r 0 10 en_int_gppm_done r 0 gppm transaction completed 9 en_int_gppm_err r 0 non-supported gppm command attempted or not enabled 8:6 reserved r 0 5 en_int_gppm_mstr_parit y err r 0 gppm master set or observed parity error (perr) 4 en_int_gppm_err_parity r 0 gppm detected parity error (perr) 3 reserved r 0 2 en_int_gppm_r_mabort r 0 gppm received master abort 1 en_int_gppm_r_tabor r 0 gppm received target abort 0 reserved r 0 offset 0x04 0fc8 gppm interrupt clear 31:11 reserved r 0 10 clr_gppm_done r 0 clear gppm transaction completed 9 clr_gppm_err r 0 clear non-supported gppm command attempted or not enabled 8:6 reserved r 0 5 clr_gppm_mstr_parity err r 0 clear gppm master set or observed parity error (perr) 4 clr_gppm_err_parity r 0 clear gppm detected parity error (perr) 3 reserved r 0 2 clr_gppm_r_mabort r 0 clear gppm received master abort 1 clr_gppm_r_tabor r 0 clear gppm received target abort 0 reserved r 0 offset 0x04 0fcc gppm interrupt set 31:11 reserved r 0 10 set_gppm_done r 0 set gppm transaction completed 9 set_gppm_err r 0 set non-supported gppm command attempted or not enabled 8:6 reserved r 0 5 set_gppm_mstr_parity_ err r 0 set gppm master set or observed parity error (perr) 4 set_gppm_err_parity r 0 set gppm detected parity error (perr) 3 reserved r 0 2 set_gppm_r_mabort r 0 set gppm received master abort 1 set_gppm_r_tabor r 0 set gppm received target abort 0 reserved r 0 offset 0x04 0fd0 dma interrupt status 31:15 reserved r 0 14 dma_xio_ack_done r 0 rising edge of xio_ack has been observed table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-39 13 reserved r 0 12 dma_done r 0 dma transaction completed 11:10 reserved r 0 9 dma_err r 0 non-supported dma command attempted or not enabled 8:6 reserved r 0 5 dma_mstr_parity_err r 0 dma master set or observed parity error (perr) 4 dma_err_parity r 0 dma detected parity error (perr) 3 reserved r 0 2 dma_r_mabort r 0 dma received master abort 1 dma_r_tabor r 0 dma received target abort 0 reserved r 0 offset 0x04 0fd4 dma interrupt enable 31:15 reserved r 0 14 en_int_dma_xio_ack_do ne r 0 rising edge of xio_ack has been observed 13 reserved r 0 12 en_int_dma_done r 0 dma transaction completed 11:10 reserved r 0 9 en_int_dma_err r 0 non-supported dma command attempted or not enabled 8:6 reserved r 0 5 en_int_dma_mstr_parity _err r 0 dma master set or observed parity error (perr) 4 en_int_dma_err_parity r 0 dma detected parity error (perr) 3 reserved r 0 2 en_int_dma_r_mabort r 0 dma received master abort 1 en_int_dma_r_tabor r 0 dma received target abort 0 reserved r 0 offset 0x04 0fd8 dma interrupt clear 31:15 reserved r 0 14 clr_dma_xio_ack_done r 0 rising edge of xio_ack has been observed 13 reserved r 0 12 clr_dma_done r 0 clear dma transaction completed 11:10 reserved r 0 9 clr_dma_err r 0 clear non-supported dma command attempted or not enabled 8:6 reserved r 0 5 clr_dma_mstr_parity_err r 0 clear dma master set or observed parity error (perr) 4 clr_dma_err_parity r 0 clear dma detected parity error (perr) 3 reserved r 0 table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-40 2 clr_dma_r_mabort r 0 clear dma received master abort 1 clr_dma_r_tabor r 0 clear dma received target abort 0 reserved r 0 offset 0x04 0fdc dma interrupt set 31:15 reserved r 0 14 set_dma_xio_ack_done r 0 set rising edge of xio_ack has been observed 13 reserved r 0 12 set_dma_done r 0 set dma transaction completed 11:10 reserved r 0 9 set_dma_err r 0 set non-supported dma command attempted or not enabled 8:6 reserved r 0 5 set_dma_mstr_parity_er r r 0 set dma master set or observed parity error (perr) 4 set_dma_err_parity r 0 set dma detected parity error (perr) 3 reserved r 0 2 set_dma_r_mabort r 0 set dma received master abort 1 set_dma_r_tabor r 0 set dma received target abort 0 reserved r 0 offset 0x04 0fe0 pci interrupt status this register represents the status of direct access to document title variable and pci slave events. 31:27 reserved r 0 26 pcii_wr_err r 0 interrupt on pci dtl initiator write error ?g 25 pcii_rd_err r 0 interrupt on pci dtl initiator read error ?g 24 xio_wr_err r 0 interrupt on xio dtl target write error ?g 23 xio_rd_err r 0 interrupt on xio dtl target read error ?g 22 pcir_wr_err r 0 interrupt on mmio register dtl target write error ?g 21 pcir_rd_err r 0 interrupt on mmio register dtl target read error 20 pwrstate_chg r 0 power management register has been changed 19 reserved r 0 18 pci2_wr_err r 0 interrupt on pci2 dtl target write error ?g 17 pci2_rd_err r 0 interrupt on pci2 dtl target read error ?g 16 pci1_wr_err r 0 interrupt on pci1 dtl target write error ?g 15 pci1_rd_err r 0 interrupt on pci1 dtl target read error ?g 14 pci_xio_ack_done r 0 rising edge of xio_ack has been observed 13:12 reserved r 0 11 serr_seen r 0 serr observed on pci bus 10 reserved r 0 table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-41 9 pci_err r 0 pci master transaction attempted when not enabled by con? register 8 err_base10_subword r 0 subword attempt to base10 aperture when restrained to word only (not used on the pnx15xx series) 7 err_base14_subword r 0 subword attempt to base14 aperture when restrained to word only 6 err_base18_subword r 0 subword attempt to base18 aperture when restrained to word only (not used on pnx15xx series) 5 pci_mstr_parity_err r 0 pci master set or observed parity error (perr) 4 err_pci_parity r 0 pci detected parity error (perr) 3 sig_serr r 0 signaled system error (serr) 2 pci_r_mabort r 0 pci received master abort 1 pci_r_tabor r 0 pci received target abort 0 pci_s_tabort r 0 pci signaled target abort offset 0x04 0fe4 pci interrupt enable 31:27 reserved r 0 26 en_int_pcii_wr_err r/w 0 enable interrupt on pci dtl initiator write error ?g 25 en_int_pcii_rd_err r/w 0 enable interrupt on pci dtl initiator read error ?g 24 en_int_xio_wr_err r/w 0 enable interrupt on xio dtl target write error ?g 23 en_int_xio_rd_err r/w 0 enable interrupt on xio dtl target read error ?g 22 en_int_pcir_wr_err r/w 0 enable interrupt on mmio register dtl target write error ?g 21 en_int_pcir_rd_err r/w 0 enable interrupt on mmio register dtl target read error 20 en_int_pwrstate_chg r 0 enable interrupt on change of power state register 19 reserved r 0 18 en_int_pci2_wr_err r/w 0 enable interrupt on pci2 dtl target write error ?g 17 en_int_pci2_rd_err r/w 0 enable interrupt on pci2 dtl target read error ?g 16 en_int_pci1_wr_err r/w 0 enable interrupt on pci1 dtl target write error ?g 15 en_int_pci1_rd_err r/w 0 enable interrupt on pci1 dtl target read error ?g 14 en_int_pci_xio_ack_don e r/w 0 enable interrupt on rising edge of xio_ack done 13:12 reserved r 0 11 en_int_serr_seen r/w 0 enable interrupt on serr observed on pci bus 10 reserved r 0 9 en_int_pci_err r/w 0 enable interrupt on pci_err ?g 8 en_int_base10_subword r/w 0 enable interrupt on subword attempt to base10 error status 7 en_int_base14_subword r/w 0 enable interrupt on subword attempt to base14 error status 6 en_int_base18_subword r/w 0 enable interrupt on subword attempt to base18 error status 5 en_int_pci_mstr_parity err r/w 0 enable interrupt on pci master parity error 4 en_int_pci_parity r/w 0 enable interrupt on pci parity error status table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-42 3 en_int_sig_serr r/w 0 enable interrupt on system error status 2 en_int_pci_r_mabort r/w 0 enable interrupt on pci received master abort status 1 en_int_pci_r_tabort r/w 0 enable interrupt on pci received target abort status 0 en_int_pci_s_tabort r/w 0 enable interrupt on pci signaled target abort status offset 0x04 0fe8 pci interrupt clear 31:27 reserved r 0 26 clr_pcii_wr_err w 0 clear pci dtl initiator write error ?g 25 clr_pcii_rd_err w 0 clear pci dtl initiator read error ?g 24 clr_xio_wr_err w 0 clear xio dtl target write error ?g 23 clr_xio_rd_err w 0 clear xio dtl target read error ?g 22 clr_pcir_wr_err w 0 clear mmio register dtl target write error ?g 21 clr_pcir_rd_err w 0 clear mmio register dtl target read error 20 clr_pwrstate_chg w 0 clear power state change register ?g 19 reserved r 0 18 clr_pci2_wr_err w 0 clear pci2 dtl target write error ?g 17 clr_pci2_rd_err w 0 clear pci2 dtl target read error ?g 16 clr_pci1_wr_err w 0 clear pci1 dtl target write error ?g 15 clr_pci1_rd_err w 0 clear pci1 dtl target read error ?g 14 clr_pci_xio_ack_done w 0 clear pci_xio_ack done ?g 13:12 reserved r 0 11 clr_serr_seen w 0 clear serr_seen ?g 10 reserved r 0 9 clr_pci_err w 0 clear pci_err ?g 8 clr_base10_subword w 0 clear subword attempt to base10 error status 7 clr_base14_subword w 0 clear subword attempt to base14 error status 6 clr_base18_subword w 0 clear subword attempt to base18 error status 5 clr_pci_mstr_parity_err w 0 clear pci master parity error 4 clr_pci_parity w 0 clear pci parity error status 3 clr_sig_serr w 0 clear system error status 2 clr_pci_r_mabort w 0 clear pci received master abort status 1 clr_pci_r_tabort w 0 clear pci received target abort status 0 clr_pci_s_tabort w 0 clear pci signaled target abort status offset 0x04 0fec pci interrupt set 31:27 reserved r 0 26 set_pcii_wr_err w 0 set pci dtl initiator write error ?g 25 set_pcii_rd_err w 0 set pci dtl initiator read error ?g 24 set_xio_wr_err w 0 set xio dtl target write error ?g 23 set_xio_rd_err w 0 set xio dtl target read error ?g table 8: registers description bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-43 22 set_pcir_wr_err w 0 set mmio register dtl target write error ?g 21 set_pcir_rd_err w 0 set mmio register dtl target read error 20 set_pwrstate_chg w 0 set change of power state register ?g 19 reserved r 0 18 set_pci2_wr_err w 0 set pci2 dtl target write error ?g 17 set_pci2_rd_err w 0 set pci2 dtl target read error ?g 16 set_pci1_wr_err w 0 set pci1 dtl target write error ?g 15 set_pci1_rd_err w 0 set pci1 dtl target read error ?g 14 set_pci_xio_ack_done w 0 set pci_xio_ack done ?g 13:12 reserved r 0 11 set_serr_seen w 0 set serr_seen ?g 10 reserved r 0 9 set_pci_err w 0 set pci_err ?g 8 set_base10_subword w 0 set subword attempt to base10 error status 7 set_base14_subword w 0 set subword attempt to base14 error status 6 set_base18_subword w 0 set subword attempt to base18 error status 5 set_pci_mstr_parity_err w 0 set pci master parity error 4 set_pci_parity w 0 set pci parity error status 3 set_sig_serr w 0 set system error status 2 set_pci_r_mabort w 0 set pci received master abort status 1 set_pci_r_tabort w 0 set pci received target abort status 0 set_pci_s_tabort w 0 set pci signaled target abort status offset 0x04 0ffc module id 31:16 module id r 0xa051 module id 15:12 major revision number r 0 major revision number 11:8 minor revision number r 1 minor revision number 7:0 mod_size r 0 module size is 4 kb. table 8: registers description bit symbol acces s value description table 9: pci con?uration registers bit symbol acces s value description offset 0x0000 device id/vendor id 31:16 device id r 0x5405 the id assigned by the pci sig representative. the value will be hard coded. 15:0 vendor id r 0x1131 value 0x1131 is the id assigned to philips semiconductors by the pci sig representative. offset 0x0004 command/status 31 parity error r/w 0 this bit will be set whenever the device detects a parity error. write 1 to clear.
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-44 30 signaled system error r/w 0 this bit is set whenever the device asserts serr. write 1 to clear. 29 received master abort r/w 0 set by the pci master when its transaction is terminated with a master abort. write 1 to clear. 28 received target abort r/w 0 set by the pci master when its transaction is terminated with a target abort. write 1 to clear. 27 signaled target abort r/w 0 set by the pci target when it terminates a transaction with a target abort. write 1 to clear. 26:25 devsel timing r 01 the pci target uses medium devsel timing. 24 master data parity error r/w 0 set by the pci master when perr is observed. 23 fast back-to-back capable r 1 the pci supports fast back-to-back transactions. 22 reserved r 0 21 66 mhz capable r cfg* 0 = 33 mhz pci (the pnx15xx series is 33 mhz). *value determined by pci_setup register. 20 capabilities list r 1 indicates a new capabilities linked list is available at offset 40h. 19:10 reserved r 0000 9 fast back-to-back enable r/w 0 enable fast back-to-back transactions for pci master. 8 serr enable r/w 0 enable serr to report system errors. 7 stepping control r 0 address stepping is not supported. 6 parity error response r/w 0 0 = no parity error response 1 = enable parity error response. 5 vga palette snoop r 0 vga is not supported. 4 memory write & invalidate r/w 0 enable use of memory write and invalidate. 3 special cycles r 0 special cycles are not supported. 2 enable bus master r/w 0 enable the pci bus master. 1 enable memory space r/w 0 enable all memory apertures. 0 io space r 0 the pci module does not respond to io transactions. offset 0x0008 class code/revision id 31:8 class code r/w* 048000 the pnx15xx series is de?ed as a multimedia device. *the boot loader may change the class code to an alternate value if done before writing to the pci_setup register. 7:0 revision id r 1 revision id. will initially be assigned to 0. revision id must not be synthesized. it will need to be changed with revised silicon, whether for bug ?es or enhancements. offset 0x000c latency timer/cache line size 31:16 reserved r 0x0000 note: bist is not implemented. header is 0. 15:8 latency timer r/w 0 latency timer 7:0 cache line size r/w 0 cache line size offset 0x0010 base10 address register table 9: pci con?uration registers bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-45 this aperture is for the sdram on the pnx15xx series. the following memory sizes are supported: 128 mb, 64 mb, 32 mb, or 16 mb. 31:28 base10 address r/w 0 upper 4 bits of base10 address of the ?st memory aperture 27:21 base10 address r/w* 0 *the base 10 can be con?ured to various aperture sizes from 2 mb to 256 mb. (see pci_setup register). depending on aperture size selected, various bits will be r/w or read only. bit: 27262524232221 256m:rororororororo 128m:rwrorororororo 64m:rwrwrororororo 32m:rwrwrwrorororo 16m:rwrwrwrwrororo 8m:rwrwrwrwrwroro 4m:rwrwrwrwrwrwro 2m:rwrwrwrwrwrwrw ro = read-only bits read back as zero. 20:4 reserved r 0 3 prefetchable r *cfg value is determined at boot time by the pci_setup register. 2:0 type r 0 indicates type 0 memory space (locatable anywhere in 32-bit address space). offset 0x0014 base14 address register this aperture will be set to 2 mb for mmio on the pnx15xx series. 31:28 base14 address r/w 0001 upper 4 bits of base14 address of the ?st memory or io aperture 27:21 base14 address r/w* 1011111 *the base 14 can be con?ured to various aperture sizes from 2 mb to 256 mb. (see pci_setup register). depending on aperture size selected, various bits will be r/w or read only. bit: 27262524232221 256m:rororororororo 128m:rwrorororororo 64m:rwrwrororororo 32m:rwrwrwrorororo 16m:rwrwrwrwrororo 8m:rwrwrwrwrwroro 4m:rwrwrwrwrwrwro 2m:rwrwrwrwrwrwrw ro = read-only bits read back as zero. 20:4 reserved r 0 3 prefetchable r *cfg value is determined at boot time by the pci_setup register. 2:0 type r 0 indicates type 0 memory space (locatable anywhere in 32-bit address space). offset 0x0018 base18 address register this aperture is for the xio on the pnx15xx series, which supports up to 128 mb of xio memory space. 31:28 base18 address r/w 0001 upper 18 bits of base address of the ?st memory or io aperture table 9: pci con?uration registers bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-46 27:21 base18 address r/w* 1100000 *the base 18 can be con?ured to various aperture sizes from 2 mb to 256 mb. (see pci_setup register). depending on aperture size selected, various bits will be r/w or read only. bit: 27262524232221 256m:rororororororo 128m:rwrorororororo 64m:rwrwrororororo 32m:rwrwrwrorororo 16m:rwrwrwrwrororo 8m:rwrwrwrwrwroro 4m:rwrwrwrwrwrwro 2m:rwrwrwrwrwrwrw ro = read-only bits read back as zero. 20:4 reserved r 0 3 prefetchable r cfg* prefetchable if con?ured as 1. *value is determined by pci_setup register. 2:0 memory r 0 this bit indicates type 0 memory aperture. offset 0x002c subsystem id/subsystem vendor id the values used in this register will be loaded into the register before entertaining any transactions on the pci bus. the boot loader will initialize control register address 0x006c with the correct values. 31:16 subsystem id r 0 subsystem id. the value for this ?ld is provided by philips pci sig representative for philips internal customers. external customers will provide their own number. 15:0 subsystem vendor id r 0 subsystem vendor id. the value for this ?ld is 1131 for philips internal customers. external customers need to apply to the pci sig to obtain a value if they do not have one already. offset 0x0030 reserved offset 0x0034 capabilities pointer 31:8 reserved r 0 7:0 cap_pointer r 0x40 indicates extended capabilities are present starting at 40. offset 0x003c max_lat, min_gnt, interrupt pin, interrupt line 31:24 max_lat r/w1 0x18 indicates the max latency tolerated in 1/4 microsecond for pci master. this value may be changed if written to before the pci_setup register. 23:16 min_gnt r/w1 0x09 indicates how long the pci master will need to use the bus. this value may be changed if written to before the pci_setup register. 15:8 interrupt_pin r 0x01 indicates which interrupt pin is used. 7:0 interrupt_line r/w 0x00 interrupt routing information offset 0x0040 power management capabilities 31:27 reserved r 0x0000 26 d2_support r cfg* 1 = device supports d2 power management state *value is determined by pci_setup register. 25 d1_support r cfg* 1 = device supports d1 power management state *value is determined by pci_setup register. 24:19 reserved r 0 table 9: pci con?uration registers bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-47 18:16 version r 010 indicates compliance with version 1.1 of pm. 15:8 next item pointer r 00 there are no other extended capabilities. 7:0 cap_id r 01 indicates this is power management data structure. offset 0x0044 pmcsr 31:2 reserved r 1:0 pwr_state rw power_state. these bits are writable only when the corresponding bit in the pmc register is enabled table 9: pci con?uration registers bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 7: pci-xio module 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 7-48
1. introduction the pnx15xx series has 61 pins that are capable of operating as general purpose software input output (gpio) pins. 16 of them are dedicated gpio pins. the other 45 pins are assigned to the other pnx15xx series modules, like the audio out module, but they can be re-used as gpio pins if they are not being used for their normal functional behavior. so these are designated as optional gpio pins that can either operate in regular mode or in gpio mode. all 61 pins support common features: software i/o - set a pin or pin group, enable a pin (or a pin group) and inspect pin values precise timestamping of internal and external events (up to 12 signals simultaneous) signal event sequence monitoring or signal generation (up to 4 signals simultaneous) timer source selection for tm3260 the 61 pins have the same gpio capabilities. however some of the dedicated gpio pins have additional features like: clocks - these pins are possible clock source for pattern generation or sampling mode. or they are simply used to provide a clock to peripherals on the pnx15xx series system board. wake-up event - used to wake-up pnx15xx series from deep sleep mode, see chapter 5 the cloc k module . boot option - determines the boot settings of pnx15xx series, see chapter 6 boot module . watchdog - this is a subset of the software i/o mode since the tm3260 cpu would toggle this pin at regular intervals in order to prevent an external watchdog to reset the entire system. alternately the internal watchdog timer of pnx15xx series system can be used, see chapter 4 reset . after a pnx15xx series system reset all the gpio pins start in gpio mode and in input mode. chapter 8: general purpose input output pins pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-2 2. functional description a simpli?d block diagram of the gpio module can be found in figure 1 . it presents the major interfaces of the gpio module. the gpio pins the mtl interface used to fetch data when operating in pattern generation mode or used to store data when the gpio module is used in sampling mode. in both cases up to 4 first in first out (fifo) memory buffers are available for one of the modes. the dcs bus interface used to convey the mmio register read and writes issued by the tm3260 cpu or any other master connected to pnx15xx series through the pci bus interface. the 5 interrupt lines which are routed directly to the tm3260 cpu. 4 lines are associated with the signal monitoring while the last interrupt line is linked to the event monitoring. the following sections describe in more details the gpio module behavior. 2.1 gpio: the basic pin behavior the pins that can be set as gpio pins is available in chapter in section 2.3 on page 1- 3 under the column ?pio #? the following t ab le 1 duplicates the gpio pin assignment. it also adds the inactive state value of the functional signal when the pin is switched from its functional mode to gpio mode. the inactive state is used to figure 1: gpio module block diagram peripheral peripheral pio interface tsu control timestamp counter registers pi ip mux 0 op ctrl 0 ip mux 3 op ctrl 3 signal pattern generation control 0 control 0 monitor signal pattern generation control 3 control 3 monitor fifo control 0 fifo control 3 rf 32x32 rf 32x32 dma request control ip mux 4 gpio core controller 0 interrupt controller 4 interrupt dcs bus dtl2pio wrapper ip_1814 adapter mtl bus gpio pins to tm326 5
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-3 avoid unpredictable behavior in a module when the pin is being used as a gpio pin. figure 2 illustrates the basic functional diagram of a gpio pin in the pnx15xx series system. table 1: gpio pin list primary function gpio number pnx15xx series module inactive state fgpo_rec_sync 60 fgpo 0 vdi_v2 59 input video/data router 1 vdi_v1 58 1 spdo 57 spdif output n/a spdi 56 spdif input 1 vdo_aux 55 output video/data router n/a vdo_d[33:32] 54 - 53 n/a vdi_d[33:32] 52 - 51 input video/data router 1 lan_mdc 50 lan 10/100 mac n/a lan_mdio 49 0 lan_rx_er 48 0 lan_rx_dv 47 0 lan_rxd[3:0] 46 - 43 0 lan_col 42 0 lan_crs 41 0 lan_tx_er 40 n/a lan_txd[3:0] 39 - 36 n/a lan_tx_en 35 n/a xio_d[15:8] 34 - 27 pci-xio 1 xio_ack 26 1 ao_sd[3:0] 25 - 22 audio out n/a ao_ws 21 n/a ai_sd[3:0] 20 - 17 audio in 0 ai_ws 16 0 gpio 15 - 0 gpio n/a
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-4 the gpio pins are controlled by software through mmio register reads and writes. the mmio registers allow to control the operating mode of the gpio pin (on a pin-by- pin basis) but also set its value or read its value. 2.1.1 gpio mode settings each gpio pin operates in 1 of 3 following modes: primary function open drain output tri-state output. there are four gpio mode control registers allocated to control the operating mode of the 61 pnx15xx series gpio pins. each pin uses a 2-bit mode ?ld located in one of the 4 mode control registers. register mc0 controls gpio pins [15:0], mc1 controls pins [31:16], etc. the 2-bit control values function is described in t ab le 2 . the complete mmio register layouts are in section 4.1 . 2.1.2 gpio data settings mmio registers when a pin is set for gpio mode, the data can be read and written by accessing one of four mask and i/o data (iod) registers. each of these registers accesses 16 of the 61 gpio signals. each register is composed of 16 mask bits and 16 iod bits. the mask and iod ?ld make up a 2-bit value: the mask bit is located in the upper 16 bits (31:16) and the iod bit is located in the lower 16 bits (15:0) of the corresponding 32-bit mmio register (groups 16 gpio pins). for example, mask figure 2: functional block diagram of a gpio pin oen pin pad input pad output gpio any module module functional input module functional output disabling logic gpio muxing gpio logic module functional outpute enable (oen) table 2: gpio mode select gpio mode description 00 retain pin mode of operation. a write with this mode does not overwrite current mode. 01 switch pin mode to primary operating mode. 10 switch pin mode to gpio mode. 11 switch pin mode to open-drain gpio (this prevents active high drive).
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-5 bit[16] is paired with iod bit[0] and [17]...[1], [18]...[2], etc. this pairing makes up the 2-bit value for programming the gpio data setting. the pairing allows to control 16 gpio pins with a single 32-bit mmio write/read from the tm3260 cpu. the available data settings are documented in t ab le 3 . the complete mmio register layouts are in section 4.2 . remark: software should treat with care these mmio registers since they do not behave as regular registers and some electrical problem can occur at board level since: writing to these bits may switch i/o signals between input & output mode. the iod ?ld of these registers re?cts the state of the actual pad of the signal. this implies that depending on the mode of the gpio pin values written to the iod bits may not affect the pin state, and therefore cannot be read back. writing a 00 (binary) value to a mask and iod ?ld pair causes no changes to the 2-bit ?ld. writing data on a gpio pin a speci? data can be written to a gpio pin by executing a single mmio register write. this is achieved by setting a ? to the corresponding mask[xx] bit and set iod bit to the desired pin value, as described in t ab le 3 . remark: the iod bits may not reflect the value written to them since these bits are used to always represent the actual signal values at the pin side. remark: after reset every gpio pin is in gpio mode. the gpio mode settings need to be programmed in order to switch the gpio into its primary operating mode. it should be noted that if the primary operating mode for a gpio is an active-low output a glitch can occur on the output if the data reaches the io logic before the output enable. therefore the software should always program it to gpio mode first and then switch it to primary operating mode as follows: 1. program mode select register in gpio mode, i.e. 10 (binary). 2. program mode select register in primary operating mode, i.e. 01 (binary). table 3: settings for mask[xx] and iod[xx] bits mask[xx] bit iod[xx] bit description 0 0 retain current stored data (a write of 00 does not overwrite current data). not readable. 0 1 data input mode, i.e. set the corresponding gpio pin in tri-state mode. 1 0 gpio output mode. drive a ??onto the corresponding gpio pin or a generated pattern (see section 2.3 ) 1 1 gpio output mode. drive a ??onto the corresponding gpio pin or a generated pattern (see section 2.3 ). note: if open-drain mode is selected, drive to ??is disabled. note: the xx portion of mask[xx] or iod[xx] identi?s the gpio number of the particular pin. refer to t ab le 1 for the number allocation and the gpio data control register table on page 8- 3 .
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-6 2.1.3 gpio pin status reading each gpio pin can be read by software using an mmio read of the proper mask and iod register. in the 32-bit register, the lower 16 bits are the gpio pin data values. software reading of the gpio input pins is always possible, even when the gpio pin is operating in its primary function mode. remark: for open drain or tri-state output values, the input value read by software is the pad value, not the driven value. 2.2 gpio: the event monitoring mode the gpio module allows to monitor events on all 61 gpio pins but also on some pnx15xx series internal signals coming from the different modules of pnx15xx series. these signals are usually signals indicating the end or the start of the capture of a buffer. documentation on the following signals can be found on each module documentation. vip timestamp: vip1_eow_vbi, vip_eow_vid ai timestamp: ai1_tstamp ao timestamp: ao1_tstamp sdpi: spdi_tstamp1, spdi_tstamp2 (see spdi mux in section 8.1 on page 3- 27 ) spdo: spdo_tstamp gpio timestamps: last_word[3:0] qvcp timestamp: qvcp_tstamp the state of these internal signals can be observed by software at any time by consulting the internal signals mmio register documented in section 4.3 . pnx15xx series integrates a total of 12 timestamp units for event monitoring. an event is de?ed by a change on the monitored signals, i.e. a high to low or a low to high transition is an event. the operating mode of the timestamp units is simple: the software running on tm3260 selects the internal signals or the gpio pins to be event monitored by setting properly the gpio_ev[15:4] mmio registers. these 12 control registers (one per timestamp unit) are used to select the source to monitor, the type of the event (rising, falling edge or both) as well as enabling the capture of the event. every time an event occurs a data_valid interrupt is generated. therefore the data_valid interrupt condition needs to be enabled by writing to the int_enable4 mmio register (the gpio generates the interrupt through interrupt line 4 which is connected to the tm3260, see t ab le 5 on page 3- 12 for source number allocation). the int_status4 mmio register indicates which of the 12 units has data ready to consume. the gpio module expects then an interrupt clear by writing to the int_clear4 mmio register.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-7 an overrun error interrupt is generated whenever new data is received before the data_valid interrupt has been cleared. the old data is not overwritten, the new data is lost. the overrun interrupt shares the same interrupt mmio registers as the valid_data interrupt. the interrupt is enabled with int_enable4, cleared through int_clear4 and consulted through int_status4 mmio registers. upon a data_valid interrupt the corresponding 32-bit timestamp unit (tsu) mmio register is stable to be read by software when the relevant data_valid_[11:0] ?g in the int_status4 mmio register is raised. the tsu register contains the timestamp information, a direction bit and a 31-bit timestamp value, see section 2.2.2 . event monitoring is commonly used for low frequency events (less than a 100 per second) while signal monitoring can be used for more frequent events. therefore the timestamp units are shared with the signal monitoring logic, section 2.3.1 . 2.2.1 timestamp reference clock the timestamp reference clock is based on a 34-bit counter running at 108 mhz. however the frequency used for all timestamping in pnx15xx series is 13.5 mhz (i.e., 108 mhz/8) which gives a better than 75 ns event resolution, i.e. only the upper 32-bit of the counter is visible by software. the counter can be observed with the time_ctr mmio register. the counter is reset by the pnx15xx series system reset. 2.2.2 timestamp format any change (according to the monitored edge event) generates a 31-bit timestamp and a 1 bit edge direction in a 32-bit word. the 1-bit direction indicator is a logic ??if a rising edge has occurred and a logic ? if a falling edge has occurred. the direction bit is the msb of the 32-bit word generated. this is pictured in figure 3 . remark: the event timestamps can be written (per monitored signal) to a memory buffer, section 2.3.1 , or to a timestamp unit register, which is software readable. 2.3 gpio: the signal monitoring & pattern generation modes there are 4 fifo queues available to perform signal monitoring or pattern generation (mutually exclusive). each fifo queue can be programmed to operate in either of these modes for a selected group of gpio pins. the fifo has dma capability to allow ef?ient cpu access to large event lists (in opposite to the event monitoring described in section 2.2 ). figure 3: 32-bit timestamp format 31-bit timestamp dir dir = 0 => falling edge dir = 1 => rising edge 0 30 31
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-8 a double dma buffer scheme is used. the base start addresses for both dma buffers in every queue is programmable as is the size of the dma buffers. the size parameter allows dma buffers to be up to 1 megabyte. both dma buffer work in a ping-pong fashion which forces the use of both of them. any of the gpio pins or the internal signals listed in section 2.2 can be selected for signal monitoring. only the gpio pins can be selected for pattern generation. the layout of the mmio register is found in section 4.4 , section 4.5 and section 4.11 . selection of the gpio or internal signals to monitor can be found in section 4.15 . 2.3.1 the signal monitoring mode the signal monitoring mode is an extension of the event monitoring that uses the 12 timestamp units. the signals, i.e. gpio pins and the internal signals) can be monitored in two different ways: event timestamping: using an event timestamps whenever a signal changes state. in this case the fifo queues are ?led with 32-bit timestamp values as de?ed in section 2.2.2 . signal sampling: sampling the signal value at a programmable frequency. in this mode up to 4 signals per fifo can be grouped for sampling. the fifo are ?led up with the signal values at each sampling clock edge. gpio mmio description for signal monitoring fifo queues the fifo queues are controlled by the gpio_ev[3:0] mmio registers. the status of the sampling and the interrupt control mmio registers are int_status[3:0], int_enable[3:0] and int_clear[3:0]. int_set[3:0] is only meant for software debug (used to trigger the hardware interrupt but using software). in the following text a ??may be used to refer to one of the 4 mmio registers, e.g. gpio_evx or one of the two ?gs, like bufx_rdy for buf2_rdy or buf2_rdy. upon reset, signal monitoring is disabled (gpio_ev[3:0].fifo_mode and gpio_ev[3:0].event_mode = 00), and the dma buffer 1 is the active dma buffer. software initiates signal monitoring by providing, per fifo, two equal size empty dma buffers and putting their base address and size in the relevant base1_ptrx, base2_ptrx and sizex mmio registers. once two valid dma buffers are assigned, monitoring can be enabled by programming the relevant gpio_evx.fifo_mode and gpio_evx.event_mode. for the enabled fifos, the gpio hardware will proceed to ?l the dma buffer 1 with timestamps or samples. once dma buffer 1 ?ls up, int_statusx.buf1_rdy is asserted, and monitoring continues a seamless transfer in dma buffer 2. if int_enablex.buf1_rdy_en is enabled, an interrupt request is generated to the chip level interrupt controller, the vic block in tm3260. the interrupt should be con?ured in the vic block in level triggered mode. when int_statusx.buf1_rdy is high, software is required to assign a new empty buffer to base1_ptrx and then clear the int_statusx].buf1_rdy ?g (by writing a ??to int_clearx.buf1_rdy_clr), before buffer 2 ?ls up which prevents an overrun.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-9 monitoring continues in dma buffer 2, until it ?ls up. at that time, int_statusx.buf2_rdy is asserted, monitoring continues in the new dma buffer 1, and the interrupt needs to be acknowledged as for dma buffer 1. if the software fails to read the full dma buffers in time (i.e buf1_rdy or buf1_rdy is not cleared in time), the overrun error ?g, int_statusx.fifo_oe, is raised and data may be lost. the int_statusx.fifo_oe error ?g can only be cleared by an explicit write of ? to the int_clearx.fifo_oe_clr bit. the interrupt if seen by the tm3260 cpu if the bit int_enablex.fifo_oe_en is set. if enabled, an interval of silence, gpio_evx.interval, can cause a bufx_rdy ?g to be asserted before all locations in the dma buffer have been ?led. therefore, whenever bufx_rdy is asserted, software is required to read the relevant int_statusx register to know exactly how many valid 32-bit words of data are in the dma buffer. the int_statusx holds the valid_ptr ?ld which gives this information. the number of valid 32-bit data words written to the dma buffers is loaded by the gpio module to the valid_ptr ?ld of the int_statusx register immediately before the gpio sets the relevant bufx_rdy ?g. if a second bufx_rdy is activated before the ?st ?g was cleared, valid_ptr cannot be updated by the gpio until the ?st activated bufx_rdy ?g is cleared by software. this clear will allow the gpio to load the new valid_ptr value for the second buffer. if both bufx_rdy ?gs are cleared at the same time, i.e if the value of valid_ptr is not needed, the valid_ptr value points back to the ?st buffer whose bufx_rdy ?g was raised. if the valid_ptr value is required to be read, each bufx_rdy must be cleared individually and in the correct order. valid_ptr is stable to be read by software when a bufx_rdy ?g is raised. base1_ptrx should be stable to be loaded by the gpio module when buf1_rdy is cleared by software and base2_ptrx should be stable to be loaded by the gpio module when buf2_rdy is cleared by software. remark: a dma buffer can ?ill up in two ways: all available locations are written to, or, in monitoring timestamped event mode, an interval of silence occurred. remark: size must be a multiple of 64 bytes. size is a static configuration register and should not change during gpio operation. the interval of silence in event timestamping sampling mode if events occur on a monitored signal and an interval of silence follows, the relevant internal buffer contents are ?shed to the dma buffers. when the contents of the internal buffer are ?shed to the dma buffer the relevant bufx_rdy ?g is set. the bufx_rdy interrupt indicates that the dma buffer is ready to be read by software and writing is switched to the second dma buffer. when an interval of silence occurs all the 64 bytes of the internal buffer are ?shed even though there may not be 64 bytes of valid data in the internal buffer. software must then read the module status to read the address where the last valid 32-bit data word, int_statusx.valid_ptr, was written.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-10 the length of the interval duration is programmed using the gpio_ev[3:0].interval ?lds. remark: if there is no internal buffer data to be flushed and no valid data in the dma buffers the interval of silence will not cause bufx_rdy to be asserted. remark: timestamping always works, even if the pin selected for monitoring is operating in its functional mode. more about the sampling mode in ?ignal sampling?a signal, figure 4 , or a group of signals can be monitored at a programmed frequency or by a selected clock input. the programmed sampling frequency is divided down from 108 mhz using a 16-bit divider. the sampling frequency is programmed in the divider[3:0].freq_div ?lds. the generated clock has a 50% duty cycle if the divider is an even number. in the case of an odd value the duty cycle is 33-66 or 66-33. instead of using the internal 108 mhz sampling clock it is possible to use one of the gpio[6:0] inputs as the sampling clock. this is enabled using the bit ?lds en_clock_sel and clock_sel in the gpio_ev[3:0] registers. some of the gpio[6:0] pins can receive a clock coming from a pnx15xx series dds clock generators, see section 2.5 . if this feature is used it is important to know that these clocks need to be turned on by programming the clock module, refer to chapter 5 the cloc k module . alternately the clocks can be generated at board level. signal sampling, should be done with a clock that is at least twice the signal frequency. the input signals to sample can be grouped together and sampled at once in the same fifo queue. it is possible to sample 1, 2 or 4 gpio inputs in one fifo queue. the sampled 1, 2 or 4 bits ?l a 32-bit word full of 32, 16 or 8 samples as pictured in figure 5 . the resulting 32-bit word of the sampled signals is written to the dma figure 4: 1-bit signal sampling 0 1 2 ... 30 31 sample: 0110....100 write 32-bits to dma buffe r monitored signal clock programmed frequency
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-11 buffer. the numbers of signals to sample together per fifo queue is programmed by setting the gpio_ev[3:0].en_io_sel ?lds. the signal selection for sampling is programmed in the io_sel[3:0] registers. 2.3.2 the signal pattern generation mode the signal pattern generation mode is the dual of the signal sampling mode. the software builds in memory dma buffers that are fetched by the gpio module. the data is then transferred to a selected group of gpio pins. similarly to the sampling mode the pattern generation mode offers two different ways to output signals: timestamp mode: the software creates dma buffers that contain 32-bit values as de?ed in section 2.2.2 . the direction bit and the timestamp information is used to drive the gpio pins with the correct polarity and to emit the sample at the correct time, i.e. when the software computed timestamped matches the internal timestamp counter. pattern mode: the gpio module outputs the dma buffer content on a select group of gpio pins. in this mode up to 4 signals per fifo can be grouped for pattern generation. pattern generation can start once the software has ?led the dma buffers. gpio mmio description for pattern generation fifo queues the fifo queues are controlled by the gpio_ev[3:0] mmio registers. the status of the sampling and the interrupt control mmio registers are int_status[3:0], int_enable[3:0] and int_clear[3:0]. int_set[3:0] is only meant for software debug (used to trigger the hardware interrupt but using software). in the following text a ??may be used to refer to one of the 4 mmio registers, e.g. gpio_evx or one of the two ?gs, like bufx_rdy for buf2_rdy or buf2_rdy. upon reset, transmission is disabled (gpio_evx.fifo_mode and gpio_evx.event_mode is reset to 00), and the dma buffer 1 is the active buffer. the system software initiates transmission by providing two dma buffers containing figure 5: up to 4-bit signal sampling 31302928272625242322212019181716151413121110 987 654 3210 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 0 1 2 3 4 5 6 7 1-bit shifted in 2-bit shifted in 4-bits shifted in 31 0 31 0 31 0 => 32 samples => 16 samples => 8 samples io_sel_0 sample io_sel_1 sample io_sel_0 sample io_sel_3 sample io_sel_2 sample io_sel_1 sample io_sel_0 sample 31 31 30 31 30 29 28
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-12 valid data and by putting their base addresses in the two basex_ptr registers, their maximum size into the size register and the number of valid words for dma buffer 1 into the pg_buf_ctrlx.buf_len bits. when the fifo queue is programmed into pattern generation mode, i.e. fifo_mode[1]=1, buf1_rdy and buf2_rdy ?gs will get set, indicating that it is ready for a new dma buffer containing valid data to be assigned. once two valid buffers are assigned and fifo queue has been enabled the buf1_rdy ?g must be cleared by software so that the gpio module can load the base1_ptr and the pg_buf_ctrlx.buf_len values. after buf1_rdy has been cleared the software can program the buf_len value for dma buffer 2. when the buf2_rdy ?g is cleared the base2_ptr and buf_len values for dma buffer 2 are loaded by the gpio modules. remark: if the buf_len values for dma buffer1 and dma buffer 2 are identical both buf1_rdy and buf2_rdy can be cleared at the same time. the gpio hardware now proceeds to empty dma buffer 1 and transmitting the samples/timestamps on the selected gpio pins. once dma buffer 1 is empty, buf1_rdy is asserted. if buf2_rdy has been cleared, transmission continues without interruption from dma buffer 2. if buf1_rdy_en is enabled, a level triggered system level interrupt request is generated. while buf1_rdy is high, the system software is required to assign a new buffer to base1_ptrx, the number of valid words in the new buffer by setting pg_buf_ctrlx.buf_len and then clear buf1_rdy (write a ??to buf1_rdy_clr) before dma buffer 2 ?ls up to avoid an underrun condition.transmission continues from buffer 2, until it is empty. at that time, buf2_rdy is asserted, and transmission continues from the new buffer 1, and so on. if an underrun condition is reached the gpio module stops the transmission, holds current values on the pins and does not warn the cpu that an underrun condition occurred. remark: the basex_ptrx and pg_buf_ctrlx.buf_len values for a dma buffer are only loaded into the gpio pattern generation logic when the relevant bufx_rdy signal has been cleared. since the pg_buf_ctrlx.buf_len register is shared between both dma buffers it important that the value in buf_len when bufx_rdy is being cleared is the correct value for that dma buffer. the basex_ptrx and buf_len values should be stable before software clears bufx_rdy. remark: the dma buffer sizes must be a multiple of 64 bytes. size is a static configuration register and must not be changed during gpio operation. pattern generation using timestamps this form of pattern generation is the inverse of event timestamping. software ?ls a (per signal) dma buffer with timed events (31-bit timestamp + 1-bit direction). the hardware performs the scheduled event on a selected gpio pin when the reference timestamp clock reaches this value.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-13 pattern generation using signal samples in this type of pattern generation software ?ls a dma buffer with sampled values. patterns can be generated, figure 6 , at a programmed frequency or by a selected clock input. the programmed sampling frequency is divided down from an internal 108 mhz clock using a 16-bit divider. the divider is programmed in the divider[3:0].freq_div ?lds. the generated clock has a 50% duty cycle if the divider is an even number. in the case of an odd value the duty cycle is 33-66 or 66-33. instead of using the internal 108 mhz clock it is also possible to use one of the gpio[6:0] input pins as the pattern generation clock. this is enabled using the bit ?lds en_clock_sel and clock_sel in the gpio_ev[3:0] registers. some of these gpio[6:0] can receive a clock coming from a pnx15xx series dds clock generators, see section 2.5 . if this feature is used it is important to know that these clocks need to be turned on by programming the clock module, refer to chapter 5 the cloc k module . alternately the clocks can be generated at board level. the signal pattern is then generated at the given frequency present on the selected gpio clock. gpio outputs can be grouped together in one fifo queue. one fifo queue can drive 1, 2 or 4 outputs. the number of outputs that can be driven by each queue is selected by programming gpio_ev[3:0].en_io_sel. the driven gpio output pins are selected by programming the io_sel[3:0] registers. the 32-bit sample read from the dma buffer is either 32 1-bit samples if 1 output is being driven by the fifo figure 6: 1-bit pattern generation 0 1 2 ... 30 31 sample: 0110....100 read from dma buffer programmed frequency generated pattern clock 11 0 1 0 0 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-14 queue, 16 2-bit samples if 2 outputs are being driven by the fifo queue or 8 4-bit samples if 4 outputs are being driven by the fifo queue. this is illustrated in figure 7 . remark: the number of samples to be generated is specified in a multiple of 32-bit word being sent by the gpio module. therefore, there is no fine-grain way to specify the exact amount of samples to be sent. additional gpio pattern generation feature: timestamp signal generation in pattern generation modes the gpio can be programmed to generate events which signal that the last 32-bit word read from a dma buffer has arrived at a gpio output pin. the event will be a positive edge pulse with the duration of the event to be greater than or equal to 148 ns (2 x [1/13.5 mhz]). the speci? event generated for each fifo queue is last_word. last_word[3:0] have the same properties as the other internal signals as described in section 2.2 and listed in section 4.15 . the generation of the last_word[3:0] internal signals is enabled by setting the en_ev_tstamp ?ld of the relevant gpio_ev[3:0] register. 2.4 gpio error behaviour a dma buffer overrun, fifo_oe, occurs if a new dma buffer is not supplied by software in time, i.e if buf1_rdy and buf2_rdy are both active. similarly to the software double dma buffering scheme, the gpio module also implements a double internal buffering scheme per fifo. this double buffering scheme allows to hide the latency of the accesses to the system memory. each internal buffer is composed of an internal 64-byte memory. in sampling mode, the gpio uses one of the internal 64-byte memories to store the being sampled data while the second 64-byte memory is being stored into memory. in pattern generation mode, the 64-byte memories are used in the opposite direction. in both cases the figure 7: up to 4-bit samples per fifo in pattern generation mode 31302928272625242322212019181716151413121110 987 654 3210 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 0 1 2 3 4 5 6 7 31 0 31 0 31 0 io_sel_0 sample io_sel_1 sample io_sel_0 sample io_sel_3 sample io_sel_2 sample io_sel_1 sample io_sel_0 sample 31 31 30 31 30 29 28 1-bit shifted out 2-bit shifted out 4-bits shifted out => 32 samples => 16 samples => 8 samples
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-15 system memory must have consumed the 64-byte memory before the gpio logic needs it again. if the system memory latency is too long then the gpio logic does not have an internal 64-byte memory to store in-coming data. in that case gpio module generates an internal overrun, int_oe, interrupt. if pattern generation mode the underrun condition is not ?gged to the cpu. if either a fifo_oe or int_oe or underrun error occurs, signal monitoring is temporarily halted, and incoming timestamps/samples will be lost. in the case of fifo_oe, sampling resumes as soon as the control software makes one or more new buffers available by clearing the relevant bufx_rdy. in the case of int_oe, the gpio module resumes normal operation as soon as the system memory allows it. int_oe and fifo_oe are ?ticky?error ?gs meaning they will remain set until an explicit software write of logic ? to fifo_oe_clr or int_oe_clr is performed. in the case of underrun the gpio module resumes as soon as data is available. 2.4.1 gpio frequency restrictions the gpio module has two frequency limitations: a hardware limitation: the maximum clock used to sample signals or generate patterns is 108 mhz. a hardware/software limitation: the system memory latency prevents to ?l or empty the internal 64-byte memories on time. this is not only a hardware limitation. indeed the memory latency is dependant on the memory clock speed, the amount of bandwidth used by the other modules of the pnx15xx series system and ultimately by the central internal arbiter settings. one fifo enabled the calculations below show the maximum frequencies allowed for signals to be monitored and patterns to be generated if only one fifo queue is enabled and the minimum latency guarantied by the system is 40 s. remark: sampling calculations assume 1-bit sampling (en_io_sel = 00 or 11). timestamping: 1 edge -> 32-bits => 16 edges = 64 bytes of data => 16 edges can occur every 40 s => 1 edge can occur every 2.5 s = 400 khz maxim um frequency. sampling: 1 edge -> 1bit => 512 edges = 64 bytes of data => 512 edges can occur every 40 s => 1 edge can occur every 78.125 ns = 12.8 mhz maxim um frequency.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-16 several fifos enabled there is one dma read channel and one dma write channel available for the 4 fifo queues. each fifo queue only makes 64 byte dma requests to one of the channels. the bandwidth allocated by the central arbiter is done separately for the read channel and for the write channel. the 4 fifos compete to access to the same dma channel. the arbitration between the 4 fifos is a priority encoded scheme. every time there is a slot available in the dma channel the local arbiter looks for the request coming from the 4 fifos in the order 0, 1, 2, and 3. there is up to 3 slots available in the dma channel. each fifo does ping-pong requests, i.e. a fifo cannot have two pending requests. if the total system bandwidth available for the 4 fifo queues in dma read or dma write is 64 bytes per 40 s and if all fifos are in read mode or write mode then each fifo gets one 64-byte request per 4 times 40 s. if 2 fifos are in read mode and the other two in write mode and, at system level, the read dma channel can get one 64-byte request per 40 s and the write dma channel can also get one 64-byte request per 40 s, then each fifo can get one 64-byte request per 2x40 s. so, in this situation the monitored/generated signal frequencies that can be tolerated are: remark: the following sampling calculations assume 1-bit sampling (en_io_sel = 00 or 11). timestamping: 1 edge -> 32 bits => 16 edges = 64 bytes of data => 16 edges can occur every 2x40 s => 1 edge can occur every 5 s = 200 khz maxim um frequency. sampling: 1 edge -> 1 bit => 512 edges = 64 bytes of data => 512 edges can occur every 2x40 s => 1 edge can occur every 156.25 ns = 6.4 mhz maxim um frequency. similar calculations for frequency tolerances can be made for 2 or 3 queues requesting dma in the same direction and at the same time and for queues which use multi-bit sampling, i.e. en_io_sel set to binary code 01 or 10. remark: the computation can be made to answer a different question: if the signal to sample is running at 12 mhz, then a sampling frequency of more than 24 mhz is required then what is the minimum latency requirement for my system memory? similarly, if several fifos are operating simultaneously with different operating frequencies (to sample different types of signals) then the different fifos will get different maximum operating frequencies because of the local arbitration.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-17 2.5 the gpio clock pins gpio[14:12,6:4] pins can be assigned to drive a clock generated from the clock module. these are clocks generated by dds clock generators. t ab le 4 shows the mapping between dds clocks and the gpio pins through which they are routed to. the clocks on pins 4, 5 and 6 can be used as clock sources for the fifo queues. in this case the clocks are ?st routed to the pins, gpio[4], gpio[5] and gpio[6], and then brought back inside the chip as any other external clock source would be. to use this feature the gpio_ev register should be programmed in the following way: gpio_ev.en_clock_sel = enabled, i.e. set to binary code 01 or 11 gpio_ev.en_dds_source = enabled, i.e. set to ?? gpio_ev.clock_sel = select between pins 4, 5 or 6 the clocks are selectable individually. the clocks on pins 12, 13 and 14 are only routed to the pnx15xx series pins and can be used as clock sources for some external devices, or loop back on the system board to gpio[3:0]. they are not directly used as internal clock sources for the fifo queues. in order to route the clocks on these gpio[14:12] pins, the dds_out_sel mmio register should be programmed appropriately. 2.6 gpio interrupts each operating fifo queue can generate 4 types of interrupts: buf1_ready: dma buffer 1 ready for reading or writing buf2_ready: dma buffer 2 ready for reading or writing fifo_oe: dma buffer overrun error int_oe: internal buffering overrun error. each timestamp unit has 2 types of interrupts: data_valid: tsu has data ready to be read int_oe: internal buffering overrun error each fifo queue has its own interrupt line to the tm3260 cpu, see t ab le 5 on page 3- 12 for source number allocation. table 4: gpio clock sources gpio[x] pin possible clock source 14 dds0 or dds2 (the selection is made in the clock module) 13 dds5 or dds1 (the selection is made in the clock module) 12 dds6 6 dds6 5 dds7 4 dds8
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-18 the 12 timestamp unit interrupts are ored together (if enabled) to produce one interrupt. therefore the 12 tsus produce only one interrupt, see t ab le 5 on page 3- 12 for source number allocation. all the interrupt status bits are ?ticky?bits and can only be cleared by writing a ??to the relevant interrupt clear register. the gpio status mmio register, vic_int_status section 4.9 , stores information about whether a fifo queue or a tsu caused the interrupt. 2.7 timer sources any of the gpio pins or internal signals can be selected as a timer source for tm3260, see t ab le 6 on page 3- 14 . the selection is done by programming the timer_io_sel mmio register, see section 4.8 . 2.8 wake-up interrupt an interrupt called ?pio_interrupt is generated whenever the gpio module requests an interrupt. this event is a ?ake-up?interrupt for the clock module to turn back on the system clocks once the pnx15xx series has been sent into deep sleep mode. 2.9 external watchdog any of the gpio pin can be used in case of an external watchdog style reset generator as the output which is pulsed regularly by software to keep a reset from occurring. wdog_out pin is a regular gpio pin without any special properties, and can be used as an extra gpio if no watchdog reset is present. 3. ir applications for each fifo queue programmed in signal monitoring or pattern generation modes, it is possible to divide the 108 mhz clock to obtain suitable frequencies for ir applications. as well as the 16-bit divider to divide the 108 mhz clock, each fifo queue has a further 5-bit divider which can be enabled if sub-carrier frequencies are required for transmission. therefore, in ir applications, a fifo queue can produce ir signals at a table 5: example of ir characteristics protocol min. pulse req. freq freq_div[15:0] carrier_div[4:0] error (%) cir (irda control) 6.67 s 150 khz 0x2d0 0x1 or disabled 0 cir with sub-carrier (tx) 0.667 s 1.5 mhz 0x24 0x14 0 rc-mm 27.77 s 36 khz 0xbb8 0x1 or disabled 0 rc-mm sub-carrier 9.26 s a 108 khz 0x1f4 0x6 0 a rf sub-carrier is 36khz, ontime should be between 25-50% of 27.77us period. (108khz = 33%)
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-19 required tx frequency and have the option to multiplex a sub-carrier frequency onto the tx frequency if required. figure 8 figure 9 and figure 10 illustrate the signal requirements. 3.1 duty-cycle programming in the rc-mm ir protocol the duty-cycle of the sub-carriers must be between 25- 50%. to accommodate this protocol and others it is possible to program the duty- cycle to be either 33%, 50%, or 66%. figure 8: example of ir tx signals with and without sub-carrier figure 9: irda control tx with sub-carrier enabled figure 10: sub-carrier multiplexing for tx ir tx signal (no sub-carrier) ir tx frequency ir tx sub-carrier frequency ir tx signal (with sub-carrier) 6.67 s 10 sub-carriers irda control signal pattern sub-carrier en_ir_carrier en_ir_carrier,carrier_div irout duty_cycle generator data generation freq_div sub-carrier 1 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-20 in the 33% and 66% duty-cycle cases freq_div must be programmed such that the resulting frequency is 3 times the actual sub-carrier frequency, i.e the minimum pulse width (high or low) is programmed. similarly, in the 50% duty-cycle case freq_div must be programmed such that the resulting frequency is 2 times the actual sub- carrier frequency. 3.2 spike filtering when signal sampling at a programmed frequency a ?tering feature is available in the gpio module which ?ters out spikes which may occur on a ir rx signal. this feature is enabled by programming the en_ir_filter and ir_filter registers. the ir_filter value represents the spike ?ter pulse width, i.e all pulses less than the ir_filter pulse width are considered spikes and not passed through to the signal monitoring control. figure 11: examples of duty cycles for ir tx signals 33% 50% 66% irout programmed freq. actual sub-carrier freq. actual sub-carrier freq. programmed freq. programmed freq. actual sub-carrier freq.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-21 4. mmio registers table 6: register summary name description 0x10,4000 mode control 0 the mode control bit pairs which control gpio pins 15-0. 0x10,4004 mode control 1 the mode control bit pairs which control gpio pins 31-16. 0x10,4008 mode control 2 the mode control bit pairs which control gpio pins 47-32. 0x10,400c mode control 3 the mode control bit pairs which control gpio pins 60-48. 0x10,4010 mask and io data 0 mask and io data for gpio pins 15-0. 0x10,4014 mask and io data 1 mask and io data for gpio pins 31-16. 0x10,4018 mask and io data 2 mask and io data for gpio pins 47-32. 0x10,401c mask and io data 3 mask and io data for gpio pins 60-48. 0x10,4020 internal signals internal signals to be timestamped, software readable. 0x10,4024 gpio_ev0 gpio signal monitoring or pattern generation control register for fifo queue 0. 0x10,4028 gpio_ev1 gpio signal monitoring or pattern generation control register for fifo queue 1. 0x10,402c gpio_ev2 gpio signal monitoring or pattern generation control register for fifo queue 2. 0x10,4030 gpio_ev3 gpio signal monitoring or pattern generation control register for fifo queue 3. 0x10,4034 gpio_ev4 gpio signal monitoring control register for timestamp unit 0 0x10,4038 gpio_ev5 gpio signal monitoring control register for timestamp unit 1 0x10,403c gpio_ev6 gpio signal monitoring control register for timestamp unit 2 0x10,4040 gpio_ev7 gpio signal monitoring control register for timestamp unit 3 0x10,4044 gpio_ev8 gpio signal monitoring control register for timestamp unit 4 0x10,4048 gpio_ev9 gpio signal monitoring control register for timestamp unit 5 0x10,404c gpio_ev10 gpio signal monitoring control register for timestamp unit 6 0x10,4050 gpio_ev11 gpio signal monitoring control register for timestamp unit 7 0x10,4054 gpio_ev12 gpio signal monitoring control register for timestamp unit 8 0x10,4058 gpio_ev13 gpio signal monitoring control register for timestamp unit 9 0x10,405c gpio_ev14 gpio signal monitoring control register for timestamp unit 10 0x10,4060 gpio_ev15 gpio signal monitoring control register for timestamp unit 11 0x10,4064 io_sel0 io select register for fifo queue 0 0x10,4068 io_sel1 io select register for fifo queue 1 0x10,406c io_sel2 io select register for fifo queue 2 0x10,4070 io_sel3 io select register for fifo queue 3 0x10,4074 pg_buf_ctrl0 pattern generation dma buffer control register. for fifo queue 0 0x10,4078 pg_buf_ctrl1 pattern generation dma buffer control register. for fifo queue 1 0x10,407c pg_buf_ctrl2 pattern generation dma buffer control register for fifo queue 2. 0x10,4080 pg_buf_ctrl3 pattern generation dma buffer control register for fifo queue 3. 0x10,4084 base1_ptr0 base address for dma buffer 1 of fifo queue 0. 0x10,4088 base1_ptr1 base address for dma buffer 1 of fifo queue 1. 0x10,408c base1_ptr2 base address for dma buffer 1 of fifo queue 2.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-22 0x10,4090 base1_ptr3 base address for dma buffer 1 of fifo queue 3. 0x10,4094 base2_ptr0 base address for dma buffer 2 of fifo queue 0. 0x10,4098 base2_ptr1 base address for dma buffer 2 of fifo queue 1. 0x10,409c base2_ptr2 base address for dma buffer 2 of fifo queue 2. 0x10,40a0 base2_ptr3 base address for dma buffer 2 of fifo queue 3. 0x10,40a4 size0 size of queue 0 in bytes. 0x10,40a8 size1 size of queue 1 in bytes. 0x10,40ac size2 size of queue 2 in bytes. 0x10,40b0 size3 size of queue 3 in bytes. 0x10,40b4 divider_0 frequency divider for fifo queue 0 0x10,40b8 divider_1 frequency divider for fifo queue 1 0x10,40bc divider_2 frequency divider for fifo queue 2 0x10,40c0 divider_3 frequency divider for fifo queue 3 0x10,40c4 tsu0 timestamp unit 0. 0x10,40c8 tsu1 timestamp unit 1 0x10,40cc tsu2 timestamp unit 2 0x10,40d0 tsu3 timestamp unit 3 0x10,40d4 tsu4 timestamp unit 4 0x10,40d8 tsu5 timestamp unit 5 0x10,40dc tsu6 timestamp unit 6 0x10,40e0 tsu7 timestamp unit 7 0x10,40e4 tsu8 timestamp unit 8 0x10,40e8 tsu9 timestamp unit 9 0x10,40ec tsu10 timestamp unit 10. 0x10,40f0 tsu11 timestamp unit 11 0x10,40f4 time_ctr 31-bit timestamp master time counter. runs at 13.5 mhz (108 mhz/8). 0x10,40f8 timer_io_sel selects gpio pins or internal signals to be use as inputs for internal tm3260 timers. 0x10,40fc vic_int_status combined interrupt status register for the vic interrupts 0x10,4100 dds_out_sel enables gpio[14:12] pins to output clocks coming from the clock module. 0x10,4fa0 int_status0 interrupt status register, combined with module status for fifo queue 0 0x10,4fa4 int_enable0 interrupt enable register for fifo queue 0 0x10,4fa8 int_clear0 interrupt clear register (by software) for fifo queue 0 0x10,4fac int_set0 interrupt set register (by software) for fifo queue 0 0x10,4fb0 int_status1 interrupt status register, combined with module status for fifo queue 1 0x10,4fb4 int_enable1 interrupt enable register for fifo queue 1 0x10,4fb8 int_clear1 interrupt clear register (by software) for fifo queue 1 0x10,4fbc int_set1 interrupt set register (by software) for fifo queue 1 0x10,4fc0 int_status2 interrupt status register, combined with module status for fifo queue 2 table 6: register summary ?ontinued name description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-23 remark: all programmable fields related to fifo queue or tsu operation described next are assumed static when the relevant fifo queue or tsu is enabled. this excludes the registers base1_ptrx and base2_ptrx and the pg_buf_ctrlx.buf_len field and the interrupt control registers. 0x10,4fc4 int_enable2 interrupt enable register for fifo queue 2 0x10,4fc8 int_clear2 interrupt clear register (by software) for fifo queue 2 0x10,4fcc int_set2 interrupt set register (by software) for fifo queue 2 0x10,4fd0 int_status3 interrupt status register, combined with module status for fifo queue 3 0x10,4fd4 int_enable3 interrupt enable register for fifo queue 3 0x10,4fd8 int_clear3 interrupt clear register (by software) for fifo queue 3 0x10,4fdc int_set3 interrupt set register (by software) for fifo queue 3 0x10,4fe0 int_status4 interrupt status register, combined with module status for tsus 0x10,4fe4 int_enable4 interrupt enable register for tsus 0x10,4fe8 int_clear4 interrupt clear register (by software) for tsus 0x10,4fec int_set4 interrupt set register (by software) for tsus 0x10,4ff4 powerdown powerdown mode, module clock switched off. 0x10,4ffc module id module identi?ation and revision information table 6: register summary ?ontinued name description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-24 4.1 gpio mode control registers table 7: gpio mode control registers bit symbol acces s value description offset 0x10,4000 mode control for gpio pins 15? 31:30 mc for gpio number 15 r/w 0b11 the mode control (mc) bit pairs control the mode of the corresponding gpio pin. the number portion of mcxx identi?s the gpio number. refer to t ab le 1 on page 8- 3 . the following values apply to writing to all of the bit pairs: 00 - retain current gpio mode of operation (will not overwrite current mode). not readable 01 - place pin in primary function mode 10 - place pin in gpio function mode 11 - place pin in gpio function with open-drain output mode 29:28 mc for gpio number 14 r/w 0b11 27:26 mc for gpio number 13 r/w 0b11 25:24 mc for gpio number 12 r/w 0b11 23:22 mc for gpio number 11 r/w 0b11 21:20 mc for gpio number 10 r/w 0b11 19:18 mc for gpio number 09 r/w 0b11 17:16 mc for gpio number 08 r/w 0b11 15:14 mc for gpio number 07 r/w 0b11 13:12 mc for gpio number 06 r/w 0b11 11:10 mc for gpio number 05 r/w 0b11 9:8 mc for gpio number 04 r/w 0b11 7:6 mc for gpio number 03 r/w 0b11 5:4 mc for gpio number 02 r/w 0b11 3:2 mc for gpio number 01 r/w 0b11 1:0 mc for gpio number 00 r/w 0b11 offset 0x10,4004 mode control for gpio pins 31?6 31:30 mc for gpio number 31 r/w 0b11 the mode control (mc) bit pairs control the mode of the corresponding gpio pin. the number portion of mcxx identi?s the gpio number. refer to t ab le 1 on page 8- 3 . the following values apply to writing to all of the bit pairs: 00 - retain current gpio mode of operation (will not overwrite current mode). not readable 01 - place pin in primary function mode 10 - place pin in gpio function mode 11 - place pin in gpio function with open-drain output mode 29:28 mc for gpio number 30 r/w 0b11 27:26 mc for gpio number 29 r/w 0b11 25:24 mc for gpio number 28 r/w 0b11 23:22 mc for gpio number 27 r/w 0b11 21:20 mc for gpio number 26 r/w 0b11 19:18 mc for gpio number 25 r/w 0b11 17:16 mc for gpio number 24 r/w 0b11 15:14 mc for gpio number 23 r/w 0b11 13:12 mc for gpio number 22 r/w 0b11 11:10 mc for gpio number 21 r/w 0b11 9:8 mc for gpio number 20 r/w 0b11 7:6 mc for gpio number 19 r/w 0b11 5:4 mc for gpio number 18 r/w 0b11 3:2 mc for gpio number 17 r/w 0b11 1:0 mc for gpio number 16 r/w 0b11
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-25 offset 0x10,4008 mode control for gpio pins 47?2 31:30 mc for gpio number 47 r/w 0b11 the mode control (mc) bit pairs control the mode of the corresponding gpio pin. the number portion of mcxx identi?s the gpio number. refer to t ab le 1 on page 8- 3 . the following values apply to writing to all of the bit pairs: 00 - retain current gpio mode of operation (will not overwrite current mode). not readable 01 - place pin in primary function mode 10 - place pin in gpio function mode 11 - place pin in gpio function with open-drain output mode 29:28 mc for gpio number 46 r/w 0b11 27:26 mc for gpio number 45 r/w 0b11 25:24 mc for gpio number 44 r/w 0b11 23:22 mc for gpio number 43 r/w 0b11 21:20 mc for gpio number 42 r/w 0b11 19:18 mc for gpio number 41 r/w 0b11 17:16 mc for gpio number 40 r/w 0b11 15:14 mc for gpio number 39 r/w 0b11 13:12 mc for gpio number 38 r/w 0b11 11:10 mc for gpio number 37 r/w 0b11 9:8 mc for gpio number 36 r/w 0b11 7:6 mc for gpio number 35 r/w 0b11 5:4 mc for gpio number 34 r/w 0b11 3:2 mc for gpio number 33 r/w 0b11 1:0 mc for gpio number 32 r/w 0b11 offset 0x10,400c mode control for gpio pins 60?8 31:26 unused the mode control (mc) bit pairs control the mode of the corresponding gpio pin. the number portion of mcxx identi?s the gpio number. refer to t ab le 1 on page 8- 3 . the following values apply to writing to all of the bit pairs: 00 - retain current gpio mode of operation (will not overwrite current mode). not readable 01 - place pin in primary function mode (see mux table) 10 - place pin in gpio function mode (see mux table) 11 - place pin in gpio function with open-drain output mode 25:24 mc for gpio number 60 r/w 0b11 23:22 mc for gpio number 59 r/w 0b11 21:20 mc for gpio number 58 r/w 0b11 19:18 mc for gpio number 57 r/w 0b11 17:16 mc for gpio number 56 r/w 0b11 15:14 mc for gpio number 55 r/w 0b11 13:12 mc for gpio number 54 r/w 0b11 11:10 mc for gpio number 53 r/w 0b11 9:8 mc for gpio number 52 r/w 0b11 7:6 mc for gpio number 51 r/w 0b11 5:4 mc for gpio number 50 r/w 0b11 3:2 mc for gpio number 49 r/w 0b11 1:0 mc for gpio number 48 r/w 0b11 table 7: gpio mode control registers bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-26 4.2 gpio data control 4.3 readable internal pnx15xx series signals table 8: gpio data control bit symbol acces s value description offset 0x10,4010 mask and io data for gpio pins 15? 31:16 mask[15:0] r/w 0x0000 see t ab le 3 on page 8- 5 for descriptions of bit values. 15:0 iod[15:0] r/w 0xffff offset 0x10,4014 mask and io data for gpio pins 31?6 31:16 mask[31:16] r/w 0x0000 see t ab le 3 on page 8- 5 for descriptions of bit values. 15:0 iod[31:16] r/w 0xffff offset 0x10,4018 mask and io data for gpio pins 47?2 31:16 mask[47:32] r/w 0x0000 see t ab le 3 on page 8- 5 for descriptions of bit values. 15:0 iod[47:32] r/w 0xffff offset 0x10,401c mask and io data for gpio pins 60?8 31:29 unused see t ab le 3 on page 8- 5 for descriptions of bit values. 28:16 mask[60:48] r/w 0x0000 15:13 unused see t ab le 3 on page 8- 5 for descriptions of bit values. 12:0 iod[60:48] r/w 0xffff table 9: readable internal pnx1500 signals bit symbol acces s value description offset 0x10,4020 internal signals 31:12 unused - - 11 last_word_q3 r 0 reads value of gpio last 32-bit word timestamp for queue 3. this is also referenced as last_word3. 10 last_word_q2 r 0 reads value of gpio last 32-bit word timestamp for queue 2. this is also referenced as last_word2. 9 last_word_q1 r 0 reads value of gpio last 32-bit word timestamp for queue 1. this is also referenced as last_word1. 8 last_word_q0 r 0 reads value of gpio last 32-bit word timestamp for queue 0. this is also referenced as last_word0. 7 vip1_eow_vbi r 0 reads value of vip end of vbi window timestamp signal. 6 vip1_eow_vid r 0 reads value of vip end of vid window timestamp signal. 5 spdi_tstamp2 r 1 reads value of spdif in timestamp 2 signal ( section 8.1 on page 3- 27 ). 4 spdi_tstamp1 r 0 reads value of spdif in timestamp 1 (word select timestamp) signal. 3 spdo_tstamp r 0 reads value of spdif out timestamp signal. 2 ai1_tstamp r 0 reads value of audio in timestamp signal. 1 ao1_tstamp r 0 reads value of audio out timestamp signal. 0 qvcp_tstamp r 0 reads value of qvcp timestamp signal.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-27 4.4 sampling and pattern generation control registers for the fifo queues table 10: sampling and pattern generation control registers for the fifo queues bit symbol acces s value description offset 0x10,4024 -> 0x030 gpio_ev<0-3> 31 unused - 30 en_ev_tstamp r/w 0 enables an event timestamp signal to be generated whenever the last 32-bit word from a dma buffer reaches the gpio output pins. this ?ld is only valid in pattern generating modes, i.e. fifo_mode[1] set to ?? 29 en_ir_carrier r/w 0 this bit enables a sub-carrier for ir transmission. freq_div[15:0] is combined with carrier_div[4:0] to generate sub-carrier and tx frequencies: 0 - ir carrier disabled, carrier_div[4:0] not used. 1 - ir carrier enabled, carrier_div[4:0] used. note: this ?ld is only valid in pattern generation using samples mode (fifo_mode=11) with en_clock_sel disabled. 28 en_ir_filter r/w 0 this bit enables a received ir signal to be ?tered. no signal pulses less than the period programmed in ir_filter are passed through to the monitoring logic. note: this ?ld is only valid in signal sampling mode (fifo_mode=01) with en_clock_sel disabled. 27:26 en_clock_sel r/w 0 enables an input signal selected by clock_sel to be used as the external clock source: 00 - clock_sel disabled 10 - clock_sel disabled 01 - clock_sel enabled, sample on positive edge 11 - clock_sel enabled, sample on negative edge note: this ?ld is only valid in signal sampling mode (fifo_mode=01) and pattern generation using samples mode (fifo_mode=11). 25:24 en_pat_gen_clk r/w 0 enables the clock generated by the frequency divider to be sent out of the chip during pattern generation using samples and frequency divider mode: 00 - en_pat_gen_clk disabled 10 - en_pat_gen_clk disabled 01 - en_pat_gen_clk enabled, output the clock as is 11 - en_pat_gen_clk enabled, output the inverted clock note: this ?ld is only valid in pattern generation using samples (fifo_mode=11) and frequency divider (en_clock_sel - disabled) mode 23:22 unused
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-28 21 en_dds_source r/w 0 enables the use of a dds clock for signal sampling or pattern generation using samples and external clock (en_clock_sel[26] = 1) mode: 0 - disabled 1 - enabled note: this ?ld is only valid in signal sampling mode (fifo_mode=01) and pattern generation using samples mode (fifo_mode=11) 20:18 clock_sel r/w 0 in signal sampling / pattern generation using samples and external clock (en_clock_sel [26] = 1) mode: this ?ld selects the gpio input pin to be used as the external clock. refer to section 4.15 for ?ld values. note: only the gpio[6:0] can be used. note: if en_dds_source = 1, then, depending on the content of dds_out_sel register, one of the gpio[6:4] pins may receive an internally generated dds clock. this clock can then be selected with clock_sel. in pattern generation using samples and the frequency divider (en_clock_sel[26] = 0) mode: this ?ld selects which gpio output pin to output the sampling frequency clock on. refer to section 4.15 for ?ld values (note only gpio[6:0] pins can be used). note: this ?ld is only valid in signal sampling mode (fifo_mode=01) and pattern generation using samples mode (fifo_mode=11). note: the gpio clock used for sampling or pattern generation must not be greater than 108 mhz. 17:16 en_io_sel r/w 0 this ?ld selects how many gpio pins should be sampled in one fifo queue: 00 - io_sel_0 enabled: 1-bit samples 11 - io_sel_0 enabled: 1-bit samples 01 - io_sel_[1:0] enabled: 2-bit samples 10 - io_sel_[3:0] enabled: 4-bit samples note: this ?ld is only valid in signal sampling mode (fifo_mode=01) or pattern generation using samples mode (fifo_mode=11). in all other modes only io_sel_0 is enabled. table 10: sampling and pattern generation control registers for the fifo queues bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-29 15:4 interval r/w 0 interval of silence. if a change is monitored on a signal and no more signal activity is monitored for a time equal to the interval of silence, writing to the current buffer is halted and a bufx_rdy interrupt is generated. writing continues to the alternate buffer. this ?ld is only valid if fifo_mode[1:0] = 00. 0x000 - disabled 0x001 - 1x128 13.5 mhz period, 9.48 s 0x002 - 2x128 13.5 mhz periods, 18.96 s 0x003 - 3x128 13.5 mhz periods, 28,44 s .... 0x3ff - 1023x128 13.5 mhz periods, 9.69 ms .... 0xfff - 4095x128 13.5 mhz periods, 38.8 ms note: this ?ld in only valid in event timestamping mode (fifo_mod e = 00 and event_mode != 00) 3:2 event_mode r/w 0 timestamping event mode: 00 - event detection disabled 01 - capture negative edge 10 - capture positive edge 11 - capture either edge note: this ?ld is valid in event timestamping mode (fifo_mode[1:0]=00) 1:0 fifo_mode r/w 0 this bit selects what mode of operation the fifo queue is in: 00 - event timestamping (or disabled if event_mode[1:0] = 00) 01 - signal sampling 10 - pattern generation using timestamps. 11 - pattern generation using samples. offset 0x10,4064 -> 0x070 io_sel a <0-3> 31:24 io_sel_3 r/w 0 this ?ld selects a gpio pin which should be merged with the gpio pin selected by io_sel_0, io_sel_1 and io_sel_2 to enable 4-bit samples in one fifo queue. note: this ?ld is only used in signal sampling mode and pattern generation using samples mode and is enabled by en_io_sel 23:16 io_sel_2 r/w 0 this ?ld selects a gpio pin which should be merged with the gpio pins selected by io_sel_0, io_sel_1 and io_sel_3 to enable 4-bit samples in one fifo queue. note: this ?ld is only used in signal sampling mode and pattern generation using samples mode and is enabled by en_io_sel 15:8 io_sel_1 r/w 0 this ?ld selects a gpio pin which should be merged with the gpio pin selected by io_sel_0 to enable 2-bit samples in one fifo queue. note: this ?ld is only used in signal sampling mode and pattern generation using samples mode and is enabled by en_io_sel table 10: sampling and pattern generation control registers for the fifo queues bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-30 7:0 io_sel_0 r/w 0 - in signal monitoring modes (fifo_mode[1]=0) this ?ld selects the gpio pin or internal global signal to be observed. refer to section 4.15 for ?ld values. - in pattern generation modes (fifo_mode[1]=1) this ?ld selects the gpio pin which is to be driven. refer to section 4.15 for ?ld values. offset 0x10,4074-> 0x080 pg_buf_ctrl<0-3> 31:18 unused - 17:0 buf_len r/w 0 this ?ld indicates how many valid 32-bit words s/w has written to a dma buffer. when buf1_rdy is cleared the buf_len value is loaded for dma buffer 1. when buf2_rdy is cleared the buf_len value is loaded for dma buffer 2. the 18-bit ?ld allows dma buffer lengths as large as 1mb. 0x00000 - 1 32-bit word 0x00001 - 2 32-bit words ..... 0x3ffff - 262143 32-bit words note: this ?ld is valid in pattern generation modes (fifo_mode[1]=1) offset 0x10,4084 -> 0x090 base1_ptr<0-3> 31:2 base1_ptr r/w 0 start byte address for dma buffer 1 of fifo queue. the base address must be 64-byte aligned. 1:0 unused - offset 0x10,4094-> 0x0a0 base2_ptr<0-3> 31:2 base2_ptr r/w 0 start byte address for dma buffer 2 of fifo queue. the base address must be 64-byte aligned. 1:0 unused - offset 0x10,40a4-> 0x0 b0size<0-3> 31:20 unused - 13:0 size r/w 0 size, in 64 bytes multiples, of each of the 2 dma buffers: 0x0001 = 64 bytes 0x0002 = 128 bytes .... 0x3fff = 1 megabytes offset 0x10,40b4 -> 0x0c0 divider<0-3> 31:23 unused - table 10: sampling and pattern generation control registers for the fifo queues bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-31 22:21 duty_cycle r/w 0 this ?ld selects the duty cycle for sub-carriers. 00 - 33% duty-cycle 01 - 50% duty-cycle 10 - 66% duty cycle 11 - illegal note: this ?ld is only valid in pattern generation modes and when en_ir_carrier = 1 table 10: sampling and pattern generation control registers for the fifo queues bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-32 20:16 18:16 carrier_div (when fifo_mode[1] =1) ir_filter (when fifo_mode[1] =0) r/w 00 00 used in ir tx applications if a sub-carrier is required for transmission. to enable this divider en_ir_carrier=1. if enabled, the ir sub-carrier frequency is de?ed by programming freq_div and the ?ntime?is de?ed by freq_div x carrier_div. 0x00 - disabled. 0x01 - disabled. 0x02 - sampling frequency is freq_div/2 ..... 0x1f - sampling frequency is freq_div/31 used in ir rx applications to ?ter a received ir signal. to enable this divider en_ir_filter=1. if enabled, ir pulses greater than ir_filter are passed through to the signal monitoring logic. 0x0 - 54/108 mhz, 0.5 s 0x1 - 108/108 mhz, 1.0 s 0x2 - 162/108 mhz, 1.5 s 0x3 - 216/108 mhz, 2.0 s 0x4 - 270/108 mhz, 2.5 s 0x5 - 324/108 mhz, 3.0 s 0x6 - 378/108 mhz, 3.5 s 0x7 - 432/108 mhz, 4.0 s note: the ?ter operates on one input per queue, this bit is the input selected by io_sel[7:0]. if used in multi-bit sampling modes (io_sel_en = 01 or 10) be aware that the ?tered signal is delayed by the selected ir_filter value with respect to the other signals sampled in the queue. table 10: sampling and pattern generation control registers for the fifo queues bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-33 15:0 freq_div r/w 0000 16-bit frequency divider for signal sampling and pattern generation using samples. if en_carrier_freq = 0 sampling freq. = 108mhz/freq_div 0x0000 - disabled. 0x0001 - sampling frequency is 108 mhz, 0x0002 - sampling/carrier frequency is 54 mhz ..... 0xffff - sampling/carrier frequency is 1.648 khz if en_carrier_freq = 1 carrier freq. = 54 mhz/freq_div 0x0000 - disabled. 0x0001 - carrier frequency is 54 mhz 0x0002 - carrier frequency is 26 mhz ..... 0xffff - carrier frequency is 824 hz a io_sel cannot be written to unless all signal generation and monitoring is disabled (fifo_mode = 00 and event_mode = 00). table 10: sampling and pattern generation control registers for the fifo queues bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-34 4.5 signal and event monitoring control registers for the timestamp units 4.6 timestamp unit registers 4.7 gpio time counter table 11: signal and event monitoring control registers for the timestamp units bit symbol acces s value description offset 0x10,4034-> 0x060 gpio_ev<4-15> 31:10 unused - 9:2 io_sel a r/w 0 this ?ld selects the gpio pin or internal global signal to be monitored. refer to section 4.15 for ?ld values. 1:0 event_mode r/w 0 timestamping event mode: 00 - event detection disabled 01 - capture negative edge 10 - capture positive edge 11 - capture either edge a io_sel cannot be written to unless timestamping is disabled (event_mode=00). table 12: timestamp unit registers bit symbol acces s value description offset 0x10,40c4->0x0f0 tsu<0-11> 31 direction r 0 this ?ld indicates the direction of the event which occurred: 0 - a falling edge 1 - a rising edge 30:0 timestamp r 0 this ?ld holds the 31-bit timestamp. table 13: gpio time counter bit symbol acces s value description offset 0x10,40f4 time_ctr 31 unused - 30:0 time_ctr r 0 gpio master time counter. this counter is incremented at a frequency of 13.5 mhz.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-35 4.8 gpio tm3260 timer input select 4.9 gpio interrupt status table 14: gpio tm3260 timer input select bit symbol acces s value description offset 0x10,4of8 timer_io_sel 31:16 unused - 15:8 timer_io_sel1 r/w 0 selects a gpio pin or an internal signal to be output onto gpio_timer[1] signal which is connected to the gpio_timer1 tm3260 timer source. see section 4.15 for valid ?ld values, i.e signal selection. 7:0 timer_io_sel0 r/w 0 selects a gpio pin or an internal signal to be output onto gpio_timer[0] signal which is connected to the gpio_timer0 tm3260 timer source. see section 4.15 for valid ?ld values, i.e signal selection. table 15: gpio interrupt status bit symbol acces s value description offset 0x10,40fc vic_int_status 31:5 unused - 4 tsu status r 0 tsu status bit for all interrupts of all 12 tsus (ored together) 3 fifo queue 3 status r 0 fifo queue 3 status bit for all interrupts (ored together) 2 fifo queue 2 status r 0 fifo queue 2 status bit for all interrupts (ored together) 1 fifo queue 1 status r 0 fifo queue 1 status bit for all interrupts (ored together) 0 fifo queue 0 status r 0 fifo queue 0 status bit for all interrupts (ored together)
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-36 4.10 clock out select table 16: clock out select bit symbol acces s value description offset 0x10,4100 dds_out_sel 31:3 unused - 2:0 dds_out_sel r/w 0 controls if the gpio[14:12] pins are used as clock outputs for the system board. by default these pins are con?ured as inputs and act as regular gpio pins: 0x000 - disabled dds_out_sel[0] 0 - gpio[12] is a gpio pin 1 - dds6 clk is sent out on gpio[12] dds_out_sel[1] 0 - gpio[13] is a gpio pin 1 - dds1 or dds5 clk is sent out on gpio[13] dds_out_sel[3] 0 - gpio[14] is a gpio pin 1 - dds0 or dds2 clk is sent out on gpio[14]
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-37 4.11 gpio interrupt registers for the fifo queues (one for each fifo queue) table 17: gpio interrupt registers for the fifo queues (one for each fifo queue) bit symbol acces s value description offset 0x10,4fa0+[4*<0-3>] int_status<0-3> 31:14 valid_ptr r 0 this ?ld indicates how many valid 32-bit words of data have been written by the gpio module to the current dma buffer: 0x00000 - 1 32-bit word 0x00001 - 2 32-bit words ..... 0x3ffff - 262143 32-bit words when a bufx_rdy signal occurs the address to read from can be calculated using valid_ptr. this ?ld is only updated by the gpio after the relevant bufx_rdy ?g is cleared by software. this ?ld is valid in signal monitoring modes only. 5:4 reserved r 0 3 int_oe r 0 internal overrun error. internal gpio data buffer has overrun before data has been written out to external dma buffer. data has been lost. only used in signal monitoring modes. 2 fifo_oe r 0 fifo overrun error. a new, empty, dma buffer was not supplied in time. only used in signal monitoring modes. 1 buf2_rdy r 0 -in signal monitoring modes: dma buffer 2 is ready to be read. it is either full or an interval of silence has occurred. -in pattern generation modes: all contents of dma buffer 2 have been read. 0 buf1_rdy r 0 -in signal monitoring modes: dma buffer1 is ready to be read. it is either full or an interval of silence has occurred. -in pattern generation modes: all contents of dma buffer 1 have been read. offset 0x10,4fa4+[4*<0-3>] int_enable<0-3> 31:4 unused - 3 int_oe_en r/w 0 active high internal overrun error interrupt enable for queue <0-3>. 2 fifo_oe_en r/w 0 active high fifo overrun error interrupt enable for queue <0-3>. 1 buf2_rdy_en r/w 0 active high buffer 2 ready interrupt enable for queue <0-3>. 0 buf1_rdy_en r/w 0 active high buffer 1 ready interrupt enable for queue <0-3>. offset 0x10,4fa8+[4*<0-3>] int_clear<0-3> 31:4 unused - 3 int_oe_clr w 0 active high internal overrun error interrupt clear for queue <0-3>. 2 fifo_oe_clr w 0 active high fifo overrun error interrupt clear for queue <0-3>. 1 buf2_rdy_clr w 0 active high buffer 2 ready interrupt clear for queue <0-3>. 0 buf1_rdy_clr w 0 active high buffer 1 ready interrupt clear for queue <0-3>. offset 0x10,4fac+[4*<0-3>] int_set<0-3> 31:4 unused -
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-38 4.12 gpio module status register for all 12 timestamp units 3 int_oe_set w 0 active high internal overrun error interrupt set for queue <0-3>. 2 fifo_oe_set w 0 active high fifo overrun error interrupt set for queue <0-3>. 1 buf2_rdy_set w 0 active high buffer 2 ready interrupt set for queue <0-3>. 0 buf1_rdy_set w 0 active high buffer 1 ready interrupt set for queue <0-3>. table 17: gpio interrupt registers for the fifo queues (one for each fifo queue) bit symbol acces s value description table 18: gpio module status register for all 12 timestamp units bit symbol acces s value description offset 0x10,4fe0 int_status4 31:24 unused - 23 int_oe_11 r 0 internal overrun error in tsu a 11. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 22 int_oe_10 r 0 internal overrun error in tsu 10. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 21 int_oe_9 r 0 internal overrun error in tsu 9. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 20 int_oe_8 r 0 internal overrun error in tsu 8. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 19 int_oe_7 r 0 internal overrun error in tsu 7. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 18 int_oe_6 r 0 internal overrun error in tsu 6. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 17 int_oe_5 r 0 internal overrun error in tsu 5. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 16 int_oe_4 r 0 internal overrun error in tsu 4. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 15 int_oe_3 r 0 internal overrun error in tsu 3. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 14 int_oe_2 r 0 internal overrun error in tsu 2. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 13 int_oe_1 r 0 internal overrun error in tsu 1. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 12 int_oe_0 r 0 internal overrun error in tsu 0. data in tsu overwritten before read by cpu (i.e before data_valid interrupt was cleared). 11 data_valid_11 r 0 data in tsu 11 is ready to be read. 10 data_valid_10 r 0 data in tsu 10 is ready to be read. 9 data_valid_9 r 0 data in tsu 9 is ready to be read. 8 data_valid_8 r 0 data in tsu 8 is ready to be read. 7 data_valid_7 r 0 data in tsu 7 is ready to be read. 6 data_valid_6 r 0 data in tsu 6 is ready to be read.
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-39 5 data_valid_5 r 0 data in tsu 5 is ready to be read. 4 data_valid_4 r 0 data in tsu 4 is ready to be read. 3 data_valid_3 r 0 data in tsu 3 is ready to be read. 2 data_valid_2 r 0 data in tsu 2 is ready to be read. 1 data_valid_1 r 0 data in tsu 1 is ready to be read. 0 data_valid_0 r 0 data in tsu 0 is ready to be read. offset 0x10,4fe4 int_enable4 31:24 unused - 23 int_oe_11_en r/w 0 internal overrun interrupt enable register for tsu 11 0 - interrupt disabled 1 - interrupt enabled 22 int_oe_10_en r/w 0 internal overrun interrupt enable register for tsu 10 0 - interrupt disabled 1 - interrupt enabled 21 int_oe_9_en r/w 0 internal overrun interrupt enable register for tsu 9 0 - interrupt disabled 1 - interrupt enabled 20 int_oe_8_en r/w 0 internal overrun interrupt enable register for tsu 8 0 - interrupt disabled 1 - interrupt enabled 19 int_oe_7_en r/w 0 internal overrun interrupt enable register for tsu 7 0 - interrupt disabled 1 - interrupt enabled 18 int_oe_6_en r/w 0 internal overrun interrupt enable register for tsu 6 0 - interrupt disabled 1 - interrupt enabled 17 int_oe_5_en r/w 0 internal overrun interrupt enable register for tsu 5 0 - interrupt disabled 1 - interrupt enabled 16 int_oe_4_en r/w 0 internal overrun interrupt enable register for tsu 4 0 - interrupt disabled 1 - interrupt enabled 15 int_oe_3_en r/w 0 internal overrun interrupt enable register for tsu 3 0 - interrupt disabled 1 - interrupt enabled 14 int_oe_2_en r/w 0 internal overrun interrupt enable register for tsu 2 0 - interrupt disabled 1 - interrupt enabled 13 int_oe_1_en r/w 0 internal overrun interrupt enable register for tsu 1 0 - interrupt disabled 1 - interrupt enabled table 18: gpio module status register for all 12 timestamp units bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-40 12 int_oe_0_en r/w 0 internal overrun interrupt enable register for tsu 0 0 - interrupt disabled 1 - interrupt enabled 11 data_valid_11_en r/w 0 data valid interrupt enable register for tsu 11 0 - interrupt disabled 1 - interrupt enabled 10 data_valid_10_en r/w 0 data valid interrupt enable register for tsu 10 0 - interrupt disabled 1 - interrupt enabled 9 data_valid_9_en r/w 0 data valid interrupt enable register for tsu 9 0 - interrupt disabled 1 - interrupt enabled 8 data_valid_8_en r/w 0 data valid interrupt enable register for tsu 8 0 - interrupt disabled 1 - interrupt enabled 7 data_valid_7_en r/w 0 data valid interrupt enable register for tsu 7 0 - interrupt disabled 1 - interrupt enabled 6 data_valid_6_en r/w 0 data valid interrupt enable register for tsu 6 0 - interrupt disabled 1 - interrupt enabled 5 data_valid_5_en r/w 0 data valid interrupt enable register for tsu 5 0 - interrupt disabled 1 - interrupt enabled 4 data_valid_4_en r/w 0 data valid interrupt enable register for tsu 4 0 - interrupt disabled 1 - interrupt enabled 3 data_valid_3_en r/w 0 data valid interrupt enable register for tsu 3 0 - interrupt disabled 1 - interrupt enabled 2 data_valid_2_en r/w 0 data valid interrupt enable register for tsu 2 0 - interrupt disabled 1 - interrupt enabled 1 data_valid_1_en r/w 0 data valid interrupt enable register for tsu 1 0 - interrupt disabled 1 - interrupt enabled 0 data_valid_0_en r/w 0 data valid interrupt enable register for tsu 0 0 - interrupt disabled 1 - interrupt enabled offset 0x10,4fe8 int_clear4 31:24 unused - 23 int_oe_11_clr w 0 active high clear for internal overrun interrupt for tsu 11. 22 int_oe_10_clr w 0 active high clear for internal overrun interrupt for tsu 10. table 18: gpio module status register for all 12 timestamp units bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-41 21 int_oe_9_clr w 0 active high clear for internal overrun interrupt for tsu 9. 20 int_oe_8_clr w 0 active high clear for internal overrun interrupt for tsu 8. 19 int_oe_7_clr w 0 active high clear for internal overrun interrupt for tsu 7. 18 int_oe_6_clr w 0 active high clear for internal overrun interrupt for tsu 6. 17 int_oe_5_clr w 0 active high clear for internal overrun interrupt for tsu 5. 16 int_oe_4_clr w 0 active high clear for internal overrun interrupt for tsu 4. 15 int_oe_3_clr w 0 active high clear for internal overrun interrupt for tsu 3. 14 int_oe_2_clr w 0 active high clear for internal overrun interrupt for tsu 2. 13 int_oe_1_clr w 0 active high clear for internal overrun interrupt for tsu 1. 12 int_oe_0_clr w 0 active high clear for internal overrun interrupt for tsu 0. 11 data_valid_11_clr w 0 active high clear for data valid interrupt for tsu 11. 10 data_valid_10_clr w 0 active high clear for data valid interrupt for tsu 10. 9 data_valid_9_clr w 0 active high clear for data valid interrupt for tsu 9. 8 data_valid_8_clr w 0 active high clear for data valid interrupt for tsu 8. 7 data_valid_7_clr w 0 active high clear for data valid interrupt for tsu 7. 6 data_valid_6_clr w 0 active high clear for data valid interrupt for tsu 6. 5 data_valid_5_clr w 0 active high clear for data valid interrupt for tsu 5. 4 data_valid_4_clr w 0 active high clear for data valid interrupt for tsu 4. 3 data_valid_3_clr w 0 active high clear for data valid interrupt for tsu 3. 2 data_valid_2_clr w 0 active high clear for data valid interrupt for tsu 2. 1 data_valid_1_clr w 0 active high clear for data valid interrupt for tsu 1. 0 data_valid_0_clr w 0 active high clear for data valid interrupt for tsu 0. offset 0x10,4fec int_set4 31:24 unused - 23 int_oe_11_set w 0 active high set for internal overrun interrupt for tsu 11. 22 int_oe_10_set w 0 active high set for internal overrun interrupt for tsu 10. 21 int_oe_9_set w 0 active high set for internal overrun interrupt for tsu 9. 20 int_oe_8_set w 0 active high set for internal overrun interrupt for tsu 8. 19 int_oe_7_set w 0 active high set for internal overrun interrupt for tsu 7. 18 int_oe_6_set w 0 active high set for internal overrun interrupt for tsu 6. 17 int_oe_5_set w 0 active high set for internal overrun interrupt for tsu 5. 16 int_oe_4_set w 0 active high set for internal overrun interrupt for tsu 4. 15 int_oe_3_set w 0 active high set for internal overrun interrupt for tsu 3. 14 int_oe_2_set w 0 active high set for internal overrun interrupt for tsu 2. 13 int_oe_1_set w 0 active high set for internal overrun interrupt for tsu 1. 12 int_oe_0_set w 0 active high set for internal overrun interrupt for tsu 0. 11 data_valid_11_set w 0 active high set for data valid interrupt for tsu 11. 10 data_valid_10_set w 0 active high set for data valid interrupt for tsu 10. table 18: gpio module status register for all 12 timestamp units bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-42 9 data_valid_9_set w 0 active high set for data valid interrupt for tsu 9. 8 data_valid_8_set w 0 active high set for data valid interrupt for tsu 8. 7 data_valid_7_set w 0 active high set for data valid interrupt for tsu 7. 6 data_valid_6_set w 0 active high set for data valid interrupt for tsu 6. 5 data_valid_5_set w 0 active high set for data valid interrupt for tsu 5. 4 data_valid_4_set w 0 active high set for data valid interrupt for tsu 4. 3 data_valid_3_set w 0 active high set for data valid interrupt for tsu 3. 2 data_valid_2_set w 0 active high set for data valid interrupt for tsu 2. 1 data_valid_1_set w 0 active high set for data valid interrupt for tsu 1. 0 data_valid_0_set w 0 active high set for data valid interrupt for tsu 0. a tsu = timestamp unit table 18: gpio module status register for all 12 timestamp units bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-43 4.13 gpio powerdown 4.14 gpio module id 4.15 gpio io_sel selection values table 19: gpio powerdown bit symbol acces s value description offset 0x10,4ff4 powerdown 31 powerdown r/w 0 0 = normal operation of peripheral. this is the reset value 1 = module is powerdown and module clock can be removed. module must respond to all reads. generate e.g. 0xdeadabba (except for reads of the powerdown bit!) module should generate err ack on writes. (except for writes to the powerdown bit!) 30:0 unused - table 20: gpio module id bit symbol acces s value description offset 0x10,4ffc module_id 31:16 module id r 0xa065 16-bit module identi?ation id. 15:12 major_rev r 0x0 8-bit major revision identi?ation id. 11:8 minor_rev r 0x1 8-bit minor revision identi?ation id. 7:0 aperture r 0x0 encoded as: aperture size = 4k*(bit_value+1). the bit value is reset to 0 meaning a 4k aperture. table 21: gpio io_sel selection values signal clock_sel/ io_sel (hex) mode last_word3 0x48 signal monitoring last_word2 0x47 signal monitoring last_word1 0x46 signal monitoring last_word0 0x45 signal monitoring vip1_eow_vbi 0x44 signal monitoring vip1_eow_vid 0x43 signal monitoring spdi_tstamp2 0x42 signal monitoring spdi_tstamp1 0x41 signal monitoring spdo_tstamp 0x40 signal monitoring ai1_tstamp 0x3f signal monitoring ao1_tstamp 0x3e signal monitoring qvcp_tstamp 0x3d signal monitoring fgpo_rec_sync 0x3c signal monitoring; pattern generation vdi_v2 0x3b signal monitoring; pattern generation vdi_v1 0x3a signal monitoring; pattern generation
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-44 spdif_o 0x39 signal monitoring; pattern generation spdif_i 0x38 signal monitoring; pattern generation vdo_aux 0x37 signal monitoring; pattern generation vdo_d[33] 0x36 signal monitoring; pattern generation vdo_d[32] 0x35 signal monitoring; pattern generation vdi_d[33] 0x34 signal monitoring; pattern generation vdi_d[32] 0x33 signal monitoring; pattern generation lan_mdc 0x32 signal monitoring; pattern generation lan_mdio 0x31 signal monitoring; pattern generation lan_rx_er 0x30 signal monitoring; pattern generation lan_rx_dv 0x2f signal monitoring; pattern generation lan_rxd[3] 0x2e signal monitoring; pattern generation lan_rxd[2] 0x2d signal monitoring; pattern generation lan_rxd[1] 0x2c signal monitoring; pattern generation lan_rxd[0] 0x2b signal monitoring; pattern generation lan_col 0x2a signal monitoring; pattern generation lan_crs 0x29 signal monitoring; pattern generation lan_tx_er 0x28 signal monitoring; pattern generation lan_txd[3] 0x27 signal monitoring; pattern generation lan_txd[2] 0x26 signal monitoring; pattern generation lan_txd[1] 0x25 signal monitoring; pattern generation lan_txd[0] 0x24 signal monitoring; pattern generation lan_tx_en 0x23 signal monitoring; pattern generation xio_d[7] 0x22 signal monitoring; pattern generation xio_d[6] 0x21 signal monitoring; pattern generation xio_d[5] 0x20 signal monitoring; pattern generation xio_d[4] 0x1f signal monitoring; pattern generation xio_d[3] 0x1e signal monitoring; pattern generation xio_d[2] 0x1d signal monitoring; pattern generation xio_d[1] 0x1c signal monitoring; pattern generation xio_d[0] 0x1b signal monitoring; pattern generation xio_ack 0x1a signal monitoring; pattern generation ao_sd[3] 0x19 signal monitoring; pattern generation ao_sd[2] 0x18 signal monitoring; pattern generation ao_sd[1] 0x17 signal monitoring; pattern generation ao_sd[0] 0x16 signal monitoring; pattern generation ao_ws 0x15 signal monitoring; pattern generation table 21: gpio io_sel selection values signal clock_sel/ io_sel (hex) mode
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-45 ai_sd[3] 0x14 signal monitoring; pattern generation ai_sd[2] 0x13 signal monitoring; pattern generation ai_sd[1] 0x12 signal monitoring; pattern generation ai_sd[0] 0x11 signal monitoring; pattern generation ai_ws 0x10 signal monitoring; pattern generation gpio[15] 0x0f signal monitoring; pattern generation gpio[14] 0x0e signal monitoring; pattern generation gpio[13] 0x0d signal monitoring; pattern generation gpio[12] 0x0c signal monitoring; pattern generation gpio[11] 0x0b signal monitoring; pattern generation gpio[10] 0x0a signal monitoring; pattern generation gpio[9] 0x09 signal monitoring; pattern generation gpio[8] 0x08 signal monitoring; pattern generation gpio[7] 0x07 signal monitoring; pattern generation gpio[6] 0x06 signal monitoring; pattern generation gpio[5] 0x05 signal monitoring; pattern generation gpio[4] 0x04 signal monitoring; pattern generation gpio[3] 0x03 signal monitoring; pattern generation gpio[2] 0x02 signal monitoring; pattern generation gpio[1] 0x01 signal monitoring; pattern generation gpio[0] 0x00 signal monitoring; pattern generation table 21: gpio io_sel selection values signal clock_sel/ io_sel (hex) mode
philips semiconductors pnx15xx series volume 1 of 1 chapter 8: general purpose input output pins 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 8-46
1. introduction the ddr controller is used to interface to off-chip ddr memory. the primary features of the ddr sdram controller include: 16- or 32-bit data bus width on ddr sdram memory side two mtl ports (one for the dma memory traf?, one for the cpu) supports x8, x16 and x32 memory devices supports 64-mbit, 128-mbit, 256-mbit and 512-mbit ddr sdram memory devices supports up to 2 ranks (physical banks) of memory devices maximum of 8 open pages maximum address range of 256 mbytes halt modes to allow for power consumption reduction programmable ddr sdram timing parameters that support ddr sdram memory devices up to 200 mhz programmable bank mapping scheme to potentially improve bandwidth utilization (see section 2.3.1 ). the ddr controller module includes an arbiter which arbitrates between the ddr burst commands coming from the two different mtl ports. after arbitration, the ddr burst command selected by the arbiter is put in a 5-entry fifo. the ddr module has a refresh counter to keep track of the refresh timing. the ddr module keeps track of the open pages in the ddr memories. up to two ddr ranks (with 4 banks each) are supported resulting in a total of eight pages. the ddr command generator decides upon which command (refresh, precharge, activate, read, or write) to generate based on the information in the 5-entry fifo, the state of the refresh counter, and the state of the ddr memories as indicated by the open page table. the pnx15xx series ddr controller follows the jedec speci?ations, [1][2]. 2. functional description refer to chapter for electrical and load constraints. chapter 9: ddr controller pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-2 2.1 start and warm start there are two different start modes for the ddr sdram controller: start, and the warm start. mmio register ip_2031_ctl provides the interface to start the ddr controller. 2.1.1 the start mode the start ?ld of mmio register ip_2031_ctl is used to trigger the start mode of the ddr sdram controller. this mode is the common start mode. it is used when neither the ddr controller nor the ddr devices are yet initialized. this is the normal condition after a system reset has occurred. the mmio registers that determine the timing and characteristics of the ddr memories should be programmed prior to the start action is triggered, since these register values may be used to con?ure the external ddr memories. the normal sequence of actions to start the ddr controller is to program the mmio registers that con?ure the different parameters of the ddr memory devices and then set the start ?ld of mmio register ip_2031_ctl to ?? this mode is used by the boot scripts. sequence of actions during the start mode during start (not warm start), the ddr sdram controller performs the following sequence of actions: apply a nop command precharge all command load extended mode register load mode register, with dll reset 256 cycles delay for ddl. precharge all command auto refresh command auto refresh command load mode register, with dll reset deactivated 256 cycles delay 2.1.2 warm start the warm start mode is a special mode where the ddr controller initializes itself but does not initialize the ddr devices. this mode is used in applications where the power of the pnx15xx series is shutdown after the ddr devices have been sent to self-refresh mode. in that state the ddr devices remained powered and therefore they retain the data and the con?uration. once the pnx15xx series power supplies are back on and an external reset is applied, the ddr controller can be started by asserting the warm_start ?ld of mmio register ip_2031_ctl. by doing so the ddr controller con?ures itself without con?uring the ddr devices. instead the
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-3 ddr controller, once con?ured, executes an exit of self-refresh mode which starts back on the ddr devices. there is no boot scripts provision for this mode, therefore an external eeprom is required to activate this mode. 2.1.3 observing start state the start and warm_start ?lds of mmio register ip_2031_ctl will be set to ??when the respective start action has completed. do not perform a start action while the ddr controller is still busy performing a previous start action. 2.2 arbitration the ddr sdram controller provides an arbiter between the dma traf? (generated by the pnx15xx series modules) and the tm3260 cpu as pictured in section 1 on page 9- 3 . the ddr sdram controller arbiter is responsible for scheduling between mtl transaction requests from the different mtl ports. the arbitration scheme has been optimized to achieve a high ddr bandwidth ef?iency (at the cost of ddr latency). 2.2.1 the first level of arbitration: between the dma and the cpu the arbitration ?w is pictured in figure 2 . figure 1: the two mtl ports of the ddr sdram controller mtl port 0 mtl port 1 ddr command request queue arbiter ddr command execute & data interface dma cpu figure 2: arbitration in the ddr controller in hrt window or cpus out of budget begin end do second level dma arbitration cpu wins arbitration
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-4 there are two mechanisms available in the arbitration: windows and account budgets. windows provide the basic means to allocate ddr bandwidth. a window is de?ed in terms of ddr controller clock cycles. windows are de?ed for dma traf? (hrt_window) and cpu traf? (cpu_window), and they alternate with each other in time. during an hrt_window, the dma traf? is given priority by the arbitration scheme. during a cpu_window, the cpu traf? is given priority by the arbitration scheme. as implied by the names cpu_window and hrt_window, windows have been introduced to divide ddr bandwidth between cpu traf? and hard real-time (hrt) dma traf?. typically, in an soc a third type of traf? is present as well: soft real_time (srt) dma traf?. this type of traf? usually has less hard real-time constraints than hrt dma traf? i.e., the bandwidth requirements can be averaged over a much larger time period (several windows) than with hrt. however, it is still necessary to ensure that this type of traf? receives ddr memory bandwidth. to this end, a cpu account is introduced. the cpu account limits (budgets) the memory bandwidth consumption by the cpu traf? to ensure that srt dma traf? receives enough memory bandwidth. the cpu account is de?ed by cpu_ratio, cpu_limit, cpu_clip and cpu_decr. the value cpu_ratio controls how much bandwidth the cpu can get. the value cpu_limit controls how many ddr bursts the cpu can take back-to-back before the cpu is out of budget. the value cpu_clip controls how much debt the cpu is allowed to build up. cpu_decr is made programmable so that the accuracy of the accounting can be increased. this is especially needed when using dynamic ratios (see section ). when the internal account exceeds cpu_limit, dma traf? is given higher priority than cpu traf?, independent of which window is active. the internal account is a saturated counter, that is, it will not wrap around on an under?w or over?w. for every ddr controller memory clock cycle, the internal counter is decremented by cpu_decr. whenever a cpu ddr burst is started, the internal counter is incremented by an amount equal to the amount of data transfer cycles, plus the value of cpu_ratio, except when a cpu mtl transaction is ?or free? a cpu mtl transaction is for free if it starts while the account value is above the cpu_clip value 1 . if a ddr burst is for free, then the account gets incremented by an amount equal to the amount of data transfer cycles, without the cpu_ratio. the cpu_clip value should always be set equal or higher than cpu_limit, otherwise cpu_limit would never be reached. by means of the accounting mechanism, the cpu bandwidth can be budgeted. in the cpu_window a cpu normally has priority over dma. for every clock cycle the cpu account gets funded with cpu_decr. for every cpu ddr burst, the costs of that burst, de?ed as cpu_ratio plus data transfer cycles, are accounted for. when the cpu account runs out of budget (account value above cpu_limit), then dma will get priority over the cpu. 1. if pre-empting of the mtl transaction is not allowed, then all ddr bursts from one mtl transaction are treated the same. so if the first ddr burst is (not) for free then the other ddr bursts for the same mtl transactions will also be (not) for free. if pre-emption of the mtl transaction is allowed, then the ?or free?decision is made separately for each ddr burst.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-5 if there is no dma then the cpu can still get the bw which it has to pay for by allowing the cpu account to borrow from its future budget. if there is a longer time period where there is no dma traf?, the cpu account could potentially build up a huge debt. as soon as dma traf? restarts, the cpu could conceivably have an extended period of time where they have a lower priority than dma (while paying off the debt). the cpu_clip value controls how much debt the cpu account is allowed to build up. after that value has been reached and there is still no dma traf? the cpu will get the bandwidth for free. the number of data transfer cycles is accounted for to approximately (excluding overhead) get the same account value before and after the free transaction. in the time zone marked ?onstant average account below clip?in figure 3 , the transfer rate is such that the average value of the cpu account is constant. in this zone, we have the following equilibrium: where #cycles_in_burst is the nominal number of cycles it takes to complete a ddr burst, being half of the burst length, and #cycles_between_arbitration is the number of clock cycles between 2 successive cpu transfers win arbitration. from this the cpu bandwidth (as percentage of maximum achievable) with constant average account is derived: in the time zone marked ?onstant average account above clip?in figure 3 , the transfer rate is such that the average value of the cpu account is constant. in this zone, we have the following equilibrium: figure 3: cpu account cpu account time transfers cpu_ratio #cycles_in_burst slope = cpu_decr/cycle cpu_limit cpu_clip constant average account below clip, see text constant average account above clip see text, cpu_ratio #cycles_in_burst + cpu_decr #cycles_between_arbitration = c pu_bw #cycles_in_burst #cycles_between_arbitration -------------------------------------------------------------------- - cpu_decr 1 cpu_ratio #cycles_in_bur st ------------------------------------- --- + ---------------------------------------------- --- - == #cycles_in_burst cpu_decr #cycles_between_arbitration =
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-6 this equilibrium is only possible with cpu_decr = 1 and all transfers back-to-back without any ef?iency loss. in other words: when the cpu account exceeds the cpu_clip value, the account can only stay constant when the cpus take 100% of the available bandwidth. this is unlikely to happen because the cpu account exceeds the cpu_limit value, giving dma a higher priority than the cpus. therefore, the cpu account will not stay above cpu_clip for long. 2.2.2 second level of arbitration 2.2.3 dynamic ratios the accounting mechanism described earlier is the static ratio variant. the problem with this approach is that the statically programmed cpu_ratio that is used, per ddr burst, can not account for signi?antly different amounts of overhead by a ddr burst that can occur in real life. to ? that problem dynamic ratios have been introduced, which can be enabled through the arb_ctl register. figure 4: arbitration when dma has priority 1 high priority cpu in budget is requesting begin end 1 low priority cpu in budget is requesting handle least recently handled low priority in budget cpu 1 high priority cpu out of budget is requesting handle least recently handled high priority cpu 1 low priority cpu out of budget is requesting handle least recently handled low priority cpu dma request handle least recently handled high priority in budget cpu handle dma request from blb any request in blb handle dma request
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-7 whenever a cpu ddr burst is started with dynamic ratios, the internal account is incremented by an amount equal to ?he number of clock cycles spent on the previous cpu ddr burst times the cpu_ratio. this way the real overhead is measured and accounted for and therefore the accounting mechanism is much more accurate. in the time zone marked ?onstant average account below clip?in figure 5 , the transfer rate is such that the average value of the cpu account is constant. in this zone, we have the following equilibrium: where #cycles_in_burst is the actual number of cycles it takes to complete this ddr burst, and #cycles_in_previous_burst is the total number of clock cycles spent on executing cpu bursts since the previous cpu command won the arbitration. from this the cpu bandwidth with constant average account is derived: considering that on average, the number of cycles in a burst will be equal to the number of cycles in the previous burst, the average cpu bandwidth is: when the cpu account exceeds the cpu_clip value, the account can only stay constant when the cpus take 100% of the available bandwidth. this is unlikely to happen because the cpu account exceeds the cpu_limit value, giving dma a higher priority than the cpus. therefore, the cpu account will not stay above cpu_clip for long. with dynamic ratios enabled, the free bandwidth is also handled differently. when the bandwidth is for free i.e., the account is above the cpu_clip value, the internal account is not incremented at all. to ensure the internal account has the same value before and after the free bandwidth ddr burst, the account never decrements figure 5: cpu account using dynamic ratios cpu account time transfers #cycles_in_previous_burst x cpu_ratio slope = cpu_decr/cycle cpu_limit cpu_clip constant average account below clip, see text #cycles_in_burst cpu_ratio #cycles_in_previous_burst cpu_decr #cycles_between_arbitration #cycles_in_burst () = c pu_bw #cycles_in_burst #cycles_between_arbitration -------------------------------------------------------------------- - cpu_decr cpu_ratio #cycles_in_previous_burst #cycles_in_burst --------------------------------------------------------------- - cpu_dec r + ---------------------------------------------------------------- --------------------------------------------------------------- ---------- --- - == a verage cpu_bw () cpu_decr cpu_ratio cpu_dec r + ------------------------------------------------------------------ --- - =
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-8 whenever a clock cycle is spent on a cpu ddr burst, even if the burst is not for free. to account for this the cpu_ratio should be set by the amount cpu_decr lower as compared to the static ratios approach. 2.2.4 pre-emption the arbitration scheme can be further ?e tuned by specifying when arbitration is done. an mtl transaction is chopped up into one or more ddr bursts, as the arbiter operates on ddr bursts. typically, the arbitration is done on an mtl transaction basis; i.e., once an mtl transaction has been selected by the arbitration scheme, all of its ddr bursts are processed before a new mtl transaction is selected. this approach tries to maximize bandwidth ef?iency by exploiting locality assumed to be present within an mtl transaction. however, it might increase the expected latency of some mtl transactions. when there is a cpu mtl transaction present while doing arbitration in an hrt window (and no dma mtl transaction present). the cpu mtl transaction is selected by the arbiter. while the cpu transaction is being processed, a dma mtl transaction becomes present (in the hrt window). the cpu mtl transaction is consuming hrt window bandwidth, while a dma mtl transaction is waiting to be selected by the arbiter. from an overall bandwidth point of view, ?ishing the cpu mtl transaction to completion might be a good idea, but the programmed bandwidth partitioning is not fully applied. to address this issue, the concept of mtl transaction pre-emption is introduced. mtl transaction pre-emption is programmable (via the mmio register arb_ctl) and can be used to interrupt an ongoing mtl transaction?efore it is completed?o favor another mtl transaction. pre-emption allows ongoing cpu mtl transactions to be interrupted by a dma mtl transaction while in the hrt_window, and allows ongoing dma mtl transactions to be interrupted by a cpu mtl transaction while in the cpu_window. interruption of an mtl transaction of the same type will never happen. any interruption will reduce the overall ef?iency of the ddr controller as it disallows exploiting locality assumed to be present within a mtl transaction. the pre-emption ?ld supports three different pre-emption settings. t ab le 1 describes the cpu pre-emption ?ld. table 1: cpu preemption field preemption field value description 0 no preemption (once a cpu mtl command has started to enter the ddr arbitration buffer, it will go completely into the ddr arbitration buffer, uninterrupted by other (cpu or dma) mtl commands). 1 preempt a cpu mtl command as it starts to enter the ddr arbitration buffer while currently active in the dma window. the cpu mtl command will only be interrupted by a dma mtl command, not by another cpu mtl command. default value 2 unde?ed 3 preempt a cpu mtl command that is currently active in the dma window (independent of when it started to enter the ddr arbitration buffer).the cpu mtl command will only be interrupted by a dma mtl command, not by another cpu mtl command.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-9 2.2.5 back log buffer (blb) the request for a ddr burst that wins the arbitration is always put in a fifo queue. this fifo is 5 levels deep to allow the ddr to look ahead and open and close pages in memory banks in order to increase ddr ef?iency. unfortunately this also means that a new high priority request that has immediately won the arbitration could possibly wait 5 full ddr bursts before it gets serviced. in a system in which almost all the available bandwidth is used (the fifo is almost always full) this can signi?antly increase the latency. usually cpu traf? requires low latency and dma traf? requires high bandwidth. in order to reduce latency for the cpus, the back log buffer (blb) has been implemented. when the blb is enabled (through the arb_ctl register), dma ddr bursts that are in the fifo can be temporarily moved to the blb. this is done under the following conditions: the fifo entries hold a dma ddr burst. no ddr burst of the same dma mtl transaction has reached the top of the fifo yet. the blb is empty a cpu ddr burst request wins the arbitration. cpu traf? has higher priority than dma traf?. (this is important in case the cpu wins arbitration, despite being lower priority than dma, due only to the absence of dma traf?.) the blb therefore allows the cpu transaction to overtake the dma transaction already in the fifo. since the ddr controller may have already opened/closed pages for the dma ddr bursts, this feature will reduce the ddr ef?iency. as soon as dma requests start winning the arbitration again, the dma ddr bursts from the blb get a higher priority than dma requests from the mtl ports. only when blb is empty, dma requests from the mtl ports can be serviced. 2.2.6 pman (hub) versus ddr controller interaction an additional factor that must be considered is the interaction of the hub and the ddr controller. the ddr controller command fifo (pipeline) is 5 entries, however the pman only allows 3 transactions to be outstanding. this means that the other two fifo stages can (and will be) occupied by transactions from one of the cpus. this can result in unexpected cpu bandwidth of up to 50%. this value is an extreme worst-case; a more realistic number (assuming some kind of video decoding) is around 15% of the gross ddr memory cycles. under the condition that the total required cpu budget is more than the maximum ?eakage?of bandwidth it is possible to reduce the additional ?eakage?(above and beyond budget) to zero by setting the value for clip = limi t+2*ratio*. the net result of this setting is that although ?eakage will still occur, it will be charged against the budget and compensated for immediately after occurrence.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-10 it should also be noted that under some circumstances the pman will be granted a request even though there is a valid cpu request pending. this can only be detected within simulations and will be very dif?ult for a user to actually discern. this condition results from the particular optimizations that were performed on the logic and only delays a cpu by one ddr transaction. the overall bandwidth for the cpu is not affected. 2.3 addressing the ddr sdram controller performs address mapping of mtl addresses onto ddr memory rank, bank, row and column addresses. the 32-bit mtl addresses, provided to the ddr controller, cover a 4-gb address range. of these 32-bit addresses, the upper four bits are ignored by the ddr controller, reducing the addressable range to 256 mb. note that the ddr controller only supports up to 256 mb of ddr memory (either implemented by a single rank or two ranks of size 128 mb). 2.3.1 memory region mapping scheme for a 32-bit ddr interface, each column is 4 bytes wide. therefore the 2 least signi?ant bits of the mtl address are ignored. for a 16-bit ddr interface (or a 32-bit ddr interface using the half width mode), each column is 2 bytes wide. therefore the least signi?ant bit of the mtl address is ignored. the mapping is de?ed by the mmio register ddr_def_bank_switch. 2^bank_switch de?es the size of the interleaving. the addressing is then done as pictured in figure 6 . changing the bank_switch value may improve/decrease performance. this is application speci?. 32-byte and 1024-byte are the recommended operating modes. this mapping can be illustrated in the following tables. in all of these examples a 32- bit ddr interface and a ddr burst length of 8 32-bit/4-byte elements (a full ddr burst transfers 8 * 4 bytes= 32 bytes). figure 6: address mapping: interleaved mode least signi?ant bit is: bit 0 for x8 bit 1 for x16 bit 2 for x32 column row bank column bank_switch 2 column_width - bank_switch row_width logical address 2^bank_switch columns bank 0 row 0 bank 1 row 0 bank 2 row 0 bank 3 row 0 2^(column_width - bank_switch) r = 2^row_width bank 0 row 1 bank 1 row 1 bank 2 row 1 bank 3 row 1 bank 0 row 2 bank 1 row 2 bank 2 row 2 bank 3 row 2 bank 0 row r-1 bank 1 row r-1 bank 2 row r-1 bank 3 row r-1
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-11 example 1: 32-byte interleaving in 32-byte interleaving mode, the mapping scheme should change the ddr bank every other 2^3 = 8 columns. the bank_switch ?ld is programmed to 3. example 2: 1024-byte interleaving in 1024-byte interleaving mode, the mapping scheme should change the ddr bank every other 2^8 = 256 columns. the bank_switch ?ld is programmed to 8. table 2: 32-byte interleaving, 256 columns mtl address range row address bank address column address 0x000:0000-0x000:001f 0x0000 0b00 0x0000-0x0007 0x000:0020-0x000:003f 0x0000 0b01 0x0000-0x0007 0x000:0040-0x000:005f 0x0000 0b10 0x0000-0x0007 0x000:0060-0x000:007f 0x0000 0b11 0x0000-0x0007 0x000:0080-0x000:009f 0x0000 0b00 0x0008-0x000f 0x000:0fe0-0x000:0fff 0x0000 0b11 0x00f8-0x00ff 0x000:1000-0x000:101f 0x0001 0b00 0x0000-0x0007 0x000:1020-0x000:103f 0x0001 0b01 0x0000-0x0007 0x000:1fe0-0x000:1fff 0x0001 0b11 0x00f8-0x00ff 0x000:2000-0x000:201f 0x0002 0b00 0x0000-0x0007 0x000:2020-0x000:203f 0x0002 0b01 0x0000-0x0007 table 3: 32-byte interleaving, 512 columns mtl address range row address bank address column address 0x000:0000-0x000:001f 0x0000 0b00 0x0000-0x0007 0x000:0020-0x000:003f 0x0000 0b01 0x0000-0x0007 0x000:0040-0x000:005f 0x0000 0b10 0x0000-0x0007 0x000:0060-0x000:007f 0x0000 0b11 0x0000-0x0007 0x000:0080-0x000:009f 0x0000 0b00 0x0008-0x000f 0x000:0feo-0x000:0fff 0x0000 0b11 0x00f8-0x00ff 0x000:1000-0x000:101f 0x0000 0b00 0x0100-0x0107 0x000:1020-0x000:103f 0x0000 0b01 0x0100-0x0107 0x000:1fe0-0x000:1fff 0x0000 0b11 0x01f8-0x01ff 0x000:2000-0x000:201f 0x0001 0b00 0x0000-0x0007 0x000:2020-0x000:203f 0x0001 0b01 0x0000-0x0007 table 4: mapping scheme: 1024-byte interleaving, 256 columns mtl address range row address bank address column address 0x000:0000-0x000:001f 0x0000 0b00 0x0000-0x0007 0x000:0020-0x000:003f 0x0000 0b00 0x0008-0x000f 0x000:0040-0x000:005f 0x0000 0b00 0x0010-0x0017 0x000:0060-0x000:007f 0x0000 0b00 0x0018-0x001f 0x000:0400-0x000:041f 0x0000 0b01 0x0000-0x0007
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-12 2.3.2 ddr memory rank locations the ddr sdram controller supports two ddr memory ranks. the location of these two memory ranks in the mtl address space is de?ed by means of mmio registers rank0_addr_lo, rank0_addr_hi, and rank1_addr_hi. rank 1 starts where rank0 leaves off in the mtl address space; i.e. the ranks are successive. programming of these mmio registers should be consistent with the size of the memories. an attempt to address an address outside of the two ddr memory ranks will result in an error, which is registered by mmio registers. erroneous addressing will still result in ddr read or write operations being performed. rank 1 starts where rank0 leaves off in the mtl address space i.e., the ranks are successive. programming these mmio registers should be consistent with the memory size. an attempt to address an address outside of the two ddr memory ranks will result in an error, which is registered by mmio registers. erroneous addressing will still result in ddr read or write operations being performed. the start addresses of the ranks should be a multiple of the respective rank sizes. the following examples will illustrate rank addressing and error detection situations. 0x000:0800-0x000:081f 0x0000 0b10 0x0000-0x0007 0x000:0c00-0x000:0c1f 0x0000 0b11 0x0000-0x0007 0x000:1000-0x000:101f 0x0001 0b00 0x0000-0x0007 0x000:1400-0x000:141f 0x0001 0b01 0x0000-0x0007 0x000:2000-0x000:201f 0x0002 0b00 0x0000-0x0007 0x000:2400-0x000:241f 0x0002 0b01 0x0000-0x0007 table 5: 1024-byte interleaving, 512 columns mtl address range row address bank address column address 0x000:0000-0x000:001f 0x0000 0b00 0x0000-0x0007 0x000:0020-0x000:003f 0x0000 0b00 0x0008-0x000f 0x000:0040-0x000:005f 0x0000 0b00 0x0010-0x0017 0x000:0060-0x000:007f 0x0000 0b00 0x0018-0x001f 0x000:0400-0x000:041f 0x0000 0b00 0x0100-0x0107 0x000:0800-0x000:081f 0x0000 0b01 0x0000-0x0007 0x000:0c00-0x000:0c1f 0x0000 0b01 0x0100-0x0107 0x000:1000-0x000:101f 0x0000 0b10 0x0000-0x0007 0x000:1400-0x000:141f 0x0000 0b10 0x0100-0x0107 0x000:2000-0x000:201f 0x0001 0b00 0x0000-0x0007 0x000:2400-0x000:241f 0x0001 0b00 0x0100-0x0107 table 4: mapping scheme: 1024-byte interleaving, 256 columns ?ontinued mtl address range row address bank address column address
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-13 some examples if rank0_addr_lo is set to 0x0800:0000, rank0_addr_hi to 0x0bff:ffff, and rank1_addr_hi to 0x0dff:ffff. this implies a 64-mb rank 0 starting at address 0x0800:0000, and a 32 mb rank 1 starting at address 0x0c00:0000. if the address 0x0900:0000 has to be mapped, the upper 4 bits of the 32-bit address are ignored. the address is located at byte offset 0x0100:0000 in rank 0. if the address 0x3900:0000 has to be mapped, the upper 4 bits of the 32-bit address are ignored. the address is located at byte offset 0x0100:0000 in rank 0. if the address 0x0c80:0000 has to be mapped, the upper 4 bits of the 32-bit address are ignored. the address is located at byte offset 0x0080:0000 in rank 1. if the address 0x3c80:0000 has to be mapped, the upper 4 bits of the 32-bit address are ignored. the address is located at byte offset 0x0080:0000 in rank 1. if the address 0x0500:0000 has to be mapped, the upper 4 bits of the 32-bit address are ignored. the address is not located within any of the two ranks, therefor an error ?g is set in mmio register err_valid to indicate this. furthermore, the ddr sdram controller output signal ?p_2031_ddr_addr_err?is made ?? the 28 lower bits of the address indicate a reference below rank 0. therefor, this address is aliased to rank 0. the aliased address is located at byte offset 0x0100:0000 in rank 0. if the address 0x0e80:0000 has to be mapped, the upper 4 bits of the 32-bit address are ignored. the address is not located within any of the two ranks, therefore an error ?g is set in mmio register err_valid to indicate this. furthermore, the ip_2031 output signal ?p_2031_ddr_addr_err?is made ?? the 28 lower bits of the address indicate a reference above rank 1. therefore, this address is aliased to rank 1 and located at byte offset 0x0080:0000 in rank 1. 2.4 clock programming the ddr clock is managed by the clock module. both clk_mem and clk_dtl_mmio must be on. 2.5 power management in order to reduce power consumption, the ddr sdram controller can be turned into halt mode. during halt mode, the clock inputs to the ddr controller may be turned off to reduce dynamic power consumption. when the clock inputs to the ddr controller are turned off, it will be non-functional. the ddr controller assumes that during halt mode the clock inputs to the dlls may be turned off as well. as a result, the ddr controller power up sequence includes resetting the dlls. note that when the clock inputs to the ddr controller are turned off, no access to the ddr controller mmio registers is possible. putting the ddr sdram controller in halt mode, and keeping the clock inputs to the ddr controller turned on, allows for safe programming of the mmio registers using the dtl mmio interface. when mmio registers ddr_mr and ddr_emr are re- programmed, a start action has to be performed (after the ddr controller is unhalted), for the new ddr values to take effect.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-14 2.5.1 halting and unhalting there are three different ways in which halting can be achieved: 1. by means of writing the halt register-?ld of a software programmable mmio register. 2. telling the ddr sdram controller to go into halt mode automatically after a certain period of inactivity. in halt mode, the ddr devices are sent into self-refresh mode. 2.5.2 mmio directed halt mmio register ip_2031_ctl, ?ld halt can be written with a ? to indicate a request for halting. write a ??to this ?ld to indicate a request for taking the ddr controller out of halt mode. direct halt directives are meant to be used when the pnx15xx series system is sent to sleep and therefore no request is supposed to happen on the mtl port. direct halt un-halt command is also used/required when changing the clock frequency of the ddr interface. software must wait for a time period equal to a minimum of 256 ddr sdram controller clocks before clocks are changed or turned off. 2.5.3 auto halt the ddr sdram controller can turn itself in halt mode when it has observed a certain period of inactivity. by programming the mmio registers halt_count and ctl a period can be de?ed and automatic halting can be activated. the ddr controller will automatically unhalt when a new mtl memory request is presented to one of its input ports. to ensure the ip_2031 can detect these mtl memory requests, the ddr controller clock inputs need to be turned on during auto halt (or at least have
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-15 to be turned on before the mtl memory request is presented to the ddr controller). this mode adds extra latency for requests to be served and should therefore be used adequately. 2.5.4 observing halt mode when the ddr sdram controller entered halt mode due to an auto halt, it will only unhalt when a mtl memory request is presented to one of its input ports. to ensure the ddr controller can detect these mtl memory requests, the ddr controller clock inputs need to be turned on during auto-halt (or at least turned on before the mtl memory request is presented to the ddr controller). therefore it is advised not to turn off the clock to the ddr controller when ?p_2031_auto_halted is ? since this is a dynamic mode controlled by the ddr controller not software. the ddr sdram controller is in halt mode if the halt_status bit in the mmio register ip_2031_ctl is set to ?? the clock, clk_mem and clk_mmio must be turned on to execute the mmio read. figure 7: ddr sdram controller start and halt state machine reset state initialization state running state halting state halt state unhalting state halting state halt state unhalting state hard reset mmio start initialization done mmio halt mmio auto halt halting done halting done unhalting done unhalting/warm start done mmio unhalt & valid mtl command ?p_2031_halted = 1 mmio warm start ?p_2031_auto_halted = 1
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-16 2.5.5 sequence of actions to enter halt mode, the ddr sdram controller performs the following sequence of actions: 1. precharge all banks (of all ranks) 2. apply a nop command 3. enter self refresh mode, with cke low, deactivate internal dll to leave halt mode, the ddr controller performs the following action: 256 ddr sdram controller memory cycles with cke high, nop commands, to activate dll. 3. application notes 3.1 memory con?urations the ddr sdram controller supports a wide range of ddr sdram memory con?urations. some examples of memory con?urations that are supported for an external data bus of 32 bits are shown in figure 8 . on the left side a single physical bank of ddr devices is connected to the ddr controller. throughout this document the term rank will be used for a physical bank in order to prevent any confusion with the logical banks inside the ddr devices. on the right hand side of figure 8 two ranks of ddr devices are connected to the ddr controller. in single rank con?urations, there is no need to drive the chip select inputs on the ddr devices from the ddr controller. in a multi-rank con?uration, each rank will receive its own chip select signal from the ddr controller. the ddr controller offers a 1 to 1 match with the pin names of the ddr memory devices.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-17 3.2 error signaling the mmio port does not support error signaling. reads from invalid addresses return the value ?? writes to invalid addresses are ignored. the errors are not reported at system level. changing mmio registers of an initiated ddr sdram controller may cause incorrect behavior. forcing the ddr controller into halt mode, programming mmio registers while in halt mode, then unhalting the ddr controller when the mmio registers have been programmed is the suggested series of actions to take. 3.3 latency the ddr sdram controller uses two pipeline stages to calculate the command(s) that will be issued to the ddr memories after a mtl command is accepted by the ddr controller. we will describe the latency of a mtl read command. assume we have a mtl read command on one of the mtl ports in cycle 0 which is accepted by the ddr controller. in cycle 1, the ddr controller will determine the ?st ddr burst for the mtl read command. in cycle 2, the ddr sdram controller will determine the ddr commands that need to be sent out on the ddr interface (we assume we do not have figure 8: examples of supported memory con?urations ddr sdram x16 ddr sdram x16 ddr sdram controller ddr sdram x16 clk/clkn cmd dq[3:2] d[31:16] clk/clkn cmd ddr sdram x16 dq[1:0] d[15:0] ddr sdram x16 ddr sdram x16 ddr sdram controller clk/clkn cmd dq[3:2] d[31:16] dq[1:0] d[15:0] ddr sdram x32 ddr sdram controller clk/clkn cmd dq d[31:0] ddr sdram controller clk/clkn cmd clk/clkn cmd dq d[31:0] ddr sdram x32 ddr sdram x32 single rank two ranks of memories
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-18 any other mtl transactions pending in the ddr controller). when the read was to an already activated row, in cycle 3 a ddr read command will appear on the ddr interface. given a cas latency of n cycles (typically the cas latency is 2, 2.5, 3, 3.5, or 4 cycles), the ?st read data element will be presented by the memory device in cycle 3 + n. to allow for safe clock domain transfer (from the ?qs clock domain to the ?lk_mtl?clock domain) and to combine two ddr read data elements into a single mtl read data element, the ddr controller takes two extra cycles before presenting the read data on the mtl interface in cycle 3 + n + 2. as a result, the lowest latency from mtl read command accept to ?st mtl read data element valid on the mtl interface is 3 + n + 2 cycles. in case of pending mtl transactions in the ddr controller, and in case of required ddr precharge and activate commands, the latency will increase. 3.4 data coherency memory requests at an mtl port of the ddr controller are processed and executed in the order that they are received. the ddr controller does not re-order the commands on a mtl interface. from this point of view data coherency between memory bus agents that connect to a single port on the ddr controller is guaranteed. however, the memory requests that are made to different mtl interfaces on the ddr sdram controller in general will not be serviced in the order that they appeared. the order in which these requests are serviced depends on the state of the ddr sdram device(s) and how the internal arbiter is programmed. the user needs to take care of data coherency between memory agents that connect to different mtl ports of the ddr controller. 3.5 programming the internal arbiter the window is de?ed by a 16-bit value that represents the size of the window in terms of ip_2031 memory clock cycles. by choosing a certain ratio between the hrt_window and the cpu_window, the available ddr bandwidth can be divided between dma traf? on mtl port 0, and cpu traf? on mtl port 1. the window size may affect the latency of traf?. by choosing a large value for hrt_window, the cpu traf? may get a large latency. however, for small window sizes the ddr controller may not be able to divide the available ddr bandwidth between dma traf? and cpu traf? as expected by the programmed window sizes. window sizes between values 20 and 100 are advised to ensure acceptable traf? latencies and proper dividing of available ddr bandwidth. e.g. to achieve a ddr bandwidth division of 25% cpu traf? and 75% dma traf?, a cpu_window of 25, and a hrt_window of 75 could be programmed. using a cpu_window of 100, and a hrt_window of 300 would probably be able to achieve a more accurate division of the bandwidth, but may result in unacceptable traf? latencies. to program the parameters for the internal arbiter, follow the steps below: 1) determine the total available bandwidth (tot_bw), based on the board ddr setup (frequency and bus width). note a mega in hz is not a m in bytes ! use an average ddr ef?iency of 73%, determine required peak hard real time bandwidth (hrt_pk), average hard real time bandwidth (hrt_avg), average soft real time (srt) and average total cpu bandwidth (cpu).
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-19 2) select the minimum (min) window size allowed; 20 or 40 are good examples. higher minimum values increase the latency, but can also slightly increase the ddr ef?iency (because more requests of one type (dma or cpu) are handled in sequence). the value 20 is based on a 128-byte transfer that takes 16 data transfer cycles on a 32-bit ddr interface. assuming an average ddr ef?iency of 80% a total of 20 cycles will be needed to start and ?ish this transfer. 3) use the minimum window value for the port with the least traf? (dma or cpu) and calculate the other window according to the following formula: if (hrt_pk < cpu) hrt_window = min; cpu_window = ((tot_bw / hrt_pk) -1)* hrt_window; else cpu_window = min; hrt_window = (hrt_pk / (tot_bw - hrt_pk)) * cpu_window; endif 4) if the selected minimum value is low and the calculated window size is much bigger than the minimum value, setting ?lways pre-empt (0x3) on the high bandwidth traf? (and maybe even ?ever?pre-empt (0x0) on the low bandwidth traf?) will be needed to make sure the low bandwidth modules get enough traf?. 5) the next parameter to calculate is cpu_ratio. to do this, ?st account for the fact that normally not all available bandwidth will be used. it is a good idea to distribute the headroom proportionally between the cpu and the soft real time dma, as shown in the following formulas: srt2 = (tot_bw - hrt_avg) * srt / (srt + cpu); cpu2 = (tot_bw - hrt_avg) * cpu / (srt + cpu); 6) the cpu_ratio and cpu_limit make sure that when the cpu is asking too much bandwidth that it gets blocked out in the cpu window and soft real time dma is allowed access instead. the cpu_ratio determines how many cycles the cpu gets blocked (versus the dma) for each cycle the ddr spends on cpu data transfers. the cpu_ratio is added to the account for each ddr burst, a ddr burst length is 4 cycles. so the formula for cpu_ratio is: cpu_ratio = 4 * (hrt_avg + srt2) / cpu2; 7) finally the cpu_limit needs to be estimated, as it basically determines how many consecutive cpu transfers are allowed to ?ish before the cpu gets blocked out. a typical value is one data cache line replacement (copy back and fetch) and one instruction fetch. assuming a data and instruction cache line size of 64 bytes, that is a total of 3*64 = 192 bytes. for each ddr burst (4 clock cycles) the ddr transfers (for a dual data rate, 32-bit ddr interface) 4*2*4=32 bytes, so 192/32 = 6 bursts are needed. the cpu_limit needs to be at least 6*cpu_ratio.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-20 in general, setting the cpu_limit too low will block the cpu too frequently causing a too high latency (execution time). setting the cpu_limit too high can completely block the soft real time dma for a long time when the hard real time dma and cpu bandwidth are peaking. but perhaps the long latency that causes the soft real time may not be a problem. 3.6 the ddr controller and the ddr memory devices the ddr sdram controller is compatible with most of the ddr sdram vendors. this is achieved when the correct timing parameters are programmed in the mmio registers holdings the timing parameters has presented in the two following sections. 4. timing diagrams and tables this section shows how programmable timing parameters direct the operation of the ddr sdram controller. it is not the intention of this section to give a complete overview of all ddr interface signaling. only the main ones are described. t ab le 6 presents the values that are used for the different timing parameters in the timing diagrams. throughout all timing diagrams a ddr burst size of eight data elements is used. in the timing diagrams, symbols are used to indicate the ddr commands that are issued by the ddr controller. an overview of these commands and their symbol convention are shown in t ab le 7 . table 6: ddr timing parameters parameter symbol value (clock cycles) cas latency t cas 2.5 minimum time between two active commands to different banks t rrd 3 minimum time between two active commands to same bank t rc 8 minimum time between auto refresh and active command t rfc 8 minimum time after last data write and precharge to same bank t wr 1 minimum time between active and precharge command t ras 8 minimum time between precharge and active command t rp 4 minimum time between active and read command t rcd_rd 4 minimum time between active and write command t rcd_wr 2 table 7: ddr commands ddr commands symbol any ddr command any activate command act precharge command pre read command read write command write auto refresh command a. rf.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-21 4.0.1 tcas timing parameter figure 9 shows two consecutive read bursts with a tcas delay of 2.5 cycles. 4.1 trrd and trc timing parameters figure 10 shows three active commands with a trrd delay of 3 cycles and a trc delay of 8 cycles. the ?st two activated commands are to different banks, the third activated command is to the same bank as the second command. 4.2 trfc timing parameter figure 11 shows a tcas of 8 cycles. figure 9: tcas timing parameter read read tcas = 2.5 tcas = 2.5 clk clk_n command address dqs dq figure 10: trrd and trc timing parameters act act act n m m trc = 8 trc = 8 trrd = 3 trrd = 3 clk clk_n command bank address figure 11: trfc timing parameter a. rf. any trfc = 8 trfc = 8 clk clk_n command
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-22 4.3 twr timing parameter figure 12 shows a twr of 1 cycle. 4.4 tras timing parameter figure 13 shows a tras of 8 cycles. 4.5 trp timing parameter figure 14 shows a trp of 4 cycles. figure 12: twr timing parameter write read twr = 1 clk clk_n command address dqs dq figure 13: tras timing parameter act pre n n tras = 8 tras = 8 clk clk_n command bank address figure 14: trp timing parameter pre any n n trp = 4 trp = 4 clk clk_n command bank
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-23 4.6 trcd_rd timing parameter figure 15 shows a trcd_rd of 4 cycles. 4.7 trcd_wr timing parameter figure 16 shows a trcd_wr of 2 cycles.3.2 asynchronous reset synchronization 5. register descriptions the ddr sdram controller contains a number of mmio registers that are used to: set generic control and read generic status information set dimensions of the ddr memories set timing characteristics of the ddr memories set arbitration parameters figure 15: trcd_rd timing parameter act read n n tcas = 2.5 clk clk_n command bank address dqs dq trcd_rd = 4 figure 16: trcd_wr timing parameter act write n n trcd_wr = 2 trcd_wr = 2 clk clk_n command bank address dqs dq
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-24 observe the performance of the ddr sdram controller observe speci?s about errors turning the ddr controller into halt mode, programming mmio registers while in halt mode, and un-halting the ddr controller when the mmio registers have been programmed, is the suggested series of actions to change mmio register values of a started ddr controller. 5.1 register summary the offsets reported in the following table are absolute offset with respect to the mmio_base value. table 8: register summary offset symbol description 0x06 5000 ip_2031_ctl ddr general control 0x06 5004 ddr_def_bank_switch ddr bank switch addressing 0x06 5008 auto_halt_limit ddr auto halt limit 0x06 5010 rank0_addr_lo ddr rank0 address low limit 0x06 5014 rank0_addr_hi ddr rank0 address high limit 0x06 5018 rank1_addr_hi ddr rank1 address high limit 0x06 5080 ddr_mr ddr mode register 0x06 5084 ddr_emr ddr extend mode register 0x06 5088 ddr_precharge_bit ddr precharge bit field 0x06 50c0 rank0_row_width ddr rank0 row bit width 0x06 50c4 rank0_column_width ddr rank0 column bit width 0x06 50d0 rank1_row_width ddr rank1 row bit width 0x06 50d4 rank1_column_width ddr rank1 column bit width 0x06 5100 ddr_trcd ddr active to read or write delay 0x06 5104 ddr_trc ddr active to active/auto refresh delay 0x06 5108 ddr_twtr ddr internal write to read command delay 0x06 510c ddr_twr ddr write recovery time 0x06 5110 ddr_trp ddr precharge command period 0x06 5114 ddr_tras ddr active to precharge command period 0x06 511c ddr_trrd ddr active bank a to active bank b command 0x06 5120 ddr_trfc ddr auto refresh command period 0x06 5124 ddr_tmrd ddr load mode register command cycle 0x06 5128 ddr_tcas ddr cas read latency 0x06 512c ddr_rf_period ddr refresh period 0x06 5180 arb_ctl ddr arbiter control 0x06 5184 arb_hrt_window ddr arbiter hard real time window 0x06 5188 arb_cpu_window ddr arbiter cpu window
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-25 5.2 register table 0x06 51c0 arb_cpu_limit ddr arbiter cpu limit 0x06 51c4 arb_cpu_ratio ddr arbiter cpu ratio 0x06 5200 pf_mtl0_rd_valid ddr performance mtl0 read valid 0x06 5204 pf_mtl0_wr_accept ddr performance mtl0 write accept 0x06 5208 pf_mtl1_rd_valid ddr performance mtl1 read valid 0x06 520c pf_mtl1_wr_accept ddr performance mtl1 write accept 0x06 5240 pf_idle ddr performance idle 0x06 5280 err_valid ddr error valid 0x06 5284 err_mtl_port ddr error mtl port 0x06 5288 err_mtl_cmd_addr ddr error mtl command address 0x06 528c err_mtl_cmd_read ddr error mtl command read 0x06 5290 err_mtl_cmd_id ddr error mtl command id 0x06 0ffc module_id ddr module id table 8: register summary offset symbol description table 9: register description bit symbol access value description generic control and status offset 0x06 5000 ip_2031_ctl 31 halt_status r 0 ?? not in halt mode. ?? halt mode. 30 auto_halt_status r 0 ?? not in halt mode. ?? halt mode. 29:16 unused r - these bits should be ignored when read and written as 0s. 15 halt r/w 0 ?? unhalt when in halt mode. ?? halt when not in halt mode. 14 auto_halt r/w 0 ?? no automatic halt. ?? allow automatic halt. 13 warm_start r/w 0 ?? perform a warm start of the controller. this will behave as a unhalt operation. this can be used to start the ddr controller without effecting the state of the external ddr memory. 12:5 unused r - these bits should be ignored when read, and written as 0s. 4 dis_write_int r 1 ?? ddr write burst cannot be interrupted by following read command. 3 ddr_dqs_per_byte r/w 0 ?? a single ?qs signal is provided for all ?q byte lane. output pin mm_dqs[0] must be used for all byte lanes. ?? a separate ?qs?signal is provided for every ?q?byte lane. these strobe signals are used to register ?q?byte lanes.
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-26 2 ddr_halve_width r/w 0 ?? the complete ?q?bus of the ddr interface is used. ?? only the lower halve of the data bus of the ddr interface is used. only ddr data bits ?m_data[15:0]?are in use. 1 spec_auto_pr r/w 0 ?? speculative auto precharge is off. ?? speculative auto precharge is on. 0 start r/w 0 ?? start ddr controller. when started, controller will return the start bit to ?? offset 0x06 5004 ddr_def_bank_switch note: addressing modes 2048_mode, 1024_mode, and the interleaving mode de?ed by the bank_switch ?ld are mutually exclusive. setting 2048_mode to ??sets the ip_2031 into 2048 byte stride mode, and makes the values of 1024_mode and bank_switch ?on? cares?for the ip_2031. when 2048_mode is ??and 1024_mode is ?? the ip_2031 is set into 1024 byte stride mode, which makes the value of bank_switch a ?on? care?for the ip_2031. 31:4 unused r - these bits should be ignored when read and written as 0s. 3:0 bank_switch r/w 3 switch banks every 2^bank_switch columns (each column has a width of 4 bytes). for 32-byte interleaving set this value equal to 0x3. for full page/row interleaving set this value equal to the column width value. only the following values are supported: 0x3, 0x4, 0x5, 0x6, 0x7, 0x8, 0x9, 0xa, and 0xb. recommended value is 3. offset 0x06 5008 auto_halt_limit 31 pon r/w 0 controls pon signal of the sstl_2 pads: ?? may be set to ??when the ddr devices are sent into self- refresh mode, i.e. after a halt command. ?? normal operation: must be set back to ??before enabling again the ddr devices, i.e. before the unhalt command. 30:0 limit r/w - after limit amount of ip_2031 idle cycles, automatic halt kicks in. the address locations of the ddr memory ranks are determined by registers rank0_addr_lo, rank0_addr_hi, and rank1_addr_hi. addresses in [rank0_addr_lo, rank0_addr_hi] are directed to rank 0, addresses in [rank0_addr_hi, rank1_addr_hi] are directed to rank 1. addresses outside the two ranks are said to cause an address error. offset 0x06 5010 rank0_addr_lo 31:0 addr_lo r/w 0x0000 0000 address at which the ddr rank 0 address space starts. offset 0x06 5014 rank0_addr_hi 31:0 addr_hi r/w 0xffff ffff address at which the ddr rank 0 address space ends. offset 0x06 5018 rank1_addr_hi 31:0 addr_hi r/w 0xffff ffff address at which the ddr rank 1 address space ends. dimension of ddr memories offset 0x06 5080 ddr_mr 31:13 unused r - these bits should be ignored when read, and written as 0s. table 9: register description bit symbol access value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-27 12:0 mr r/w 0x043 mode register. the assumption is the dll reset bit is at location 8. use the datasheet of the ddr memory to determine the value of this register. the reset value of this register represents a cas latency of 3.0 cycles, and a burst length of 8. make sure to select a burst size of 8, and a sequential burst type to ensure correct ip_2031 operation. the following is taken from a ddr datasheet and describes the different bits of the mode register. bits 0 up to 2: burst length bit 3: burst type (?? sequential, ?? interleaved) bits 4 up to 6: cas latency bits 7 and up: operating mode (?? normal operation, ?? normal operation/reset dll) offset 0x06 5084 ddr_emr 31:13 unused r - these bits should be ignored when read, and written as 0s. 12:0 emr r/w 0x000 extended mode register. use the datasheet of the ddr memory to determine the value of this register. for emulation purposes it may be required to disable the dll. to this end, make sure that bit 0 of this register contains a ?? in normal (non-emulation) mode, make sure that bit 0 of this register contains a ?? the following is taken from a ddr datasheet and describes the different bits of the extended mode register. bit 0: dll (?? enable, ?? disable). bit 1: drive strength (?? normal, ?? reduced) bit 2: qfc mode bits 3 and up: operating mode offset 0x06 5088 ddr_precharge_bit 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 precharge_bit r/w 0xa column bit responsible for precharge. only the values 0x8 (bit 8) and 0xa (bit 10) are supported. offset 0x06 50c0 rank0_row_width 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 row_width r/w 0xd row dimension: 2^row_width rows i.e., a value of 0xc speci?s 2^12 = 4096 rows. only the following values are supported: 0x8, 0x9, 0xa, 0xb, 0xc, and 0xd (supporting 256 up to 8192 rows). offset 0x06 50c4 rank0_column_width 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 column_width r/w 0xa column dimension: 2^column_width columns (each column has a width of 32 bit). i.e., a value of 0xa speci?s 2^10 = 1024 columns of 32 bit each. only the following values are supported: 0x8, 0x9, 0xa, and 0xb (supporting 256 up to 2048 columns). offset 0x06 50d0 rank1_row_width 31:4 unused r - these bits should be ignored when read, and written as 0s. table 9: register description bit symbol access value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-28 3:0 row_width r/w 0xd row dimension: 2^row_width rows. i.e., a value of 0xc speci?s 2^12 = 4096 rows. only the following values are supported: 0x8, 0x9, 0xa, 0xb, 0xc, and 0xd (supporting 256 up to 8192 rows). offset 0x06 50d4 rank1_column_width 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 column_width r/w 0xa column dimension: 2^column_width columns (each column has a width of 32 bit). i.e., a value of 0xa speci?s 2^10 = 1024 columns of 32 bit each. only the following values are supported: 0x8, 0x9, 0xa, and 0xb (supporting 256 up to 2048 columns). timing characteristics offset 0x06 5100 ddr_trcd 31:20 unused r - these bits should be ignored when read, and written as 0s. 19:16 trcd_wr r/w 2 minimum time between active and write command (ras to cas delay). when the datasheet of the ddr memory does not specify a value for this timing parameter, use the value as speci?d for trcd. must be greater or equal than trap. 15:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 trcd_rd r/w 4 minimum time between active and read command (ras to cas delay). when the datasheet of the ddr memory does not specify a value for this timing parameter, use the value as speci?d for trcd. must be greater or equal than trap. offset 0x06 5104 ddr_trc 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 trc r/w 0xd minimum time between two active commands to the same bank. offset 0x06 5108 ddr_twtr 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 twtr r/w 2 write to read command delay offset 0x06 510c ddr_twr 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 twr r/w 3 write recovery time. must be greater or equal than twr_a. twr+trp must be greater or equal than tdal. offset 0x06 5110 ddr_trp 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 trp r/w 4 precharge command period. twr+trp must be greater or equal than tdal. offset 0x06 5114 ddr_tras 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 tras r/w 9 minimum delay from active to precharge. offset 0x06 511c ddr_trrd 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 trrd r/w 2 active bank a to active bank b command table 9: register description bit symbol access value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-29 offset 0x06 5120 ddr_trfc 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 trfc r/w 0xf auto refresh command period. offset 0x06 5124 ddr_tmrd 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 tmrd r/w 2 load mode register command cycle time. offset 0x06 5128 ddr_tcas 31:4 unused r - these bits should be ignored when read, and written as 0s. 3:0 tcas r/w 8 cas read latency, speci?d in halve cycles. i.e., a value of 0b0111 (7) represents a cas delay of 3.5 cycles (7 halve cycles). offset 0x06 512c ddr_rf_period 31:6 unused r - these bits should be ignored when read, and written as 0s. 15:0 rf_period r/w 3515 refresh period expressed in terms of cycles. typically a refresh is required at an average interval of 15.625 us. for a 100 mhz. device this translates into a rf_period value of 1562. for a 200 mhz. device this translates into a rf_period value of 3125. arbitration parameters offset 0x06 5180 arb_ctl 31 cpu_dma_decr r/w 1 ?? do not decrement cpu counters when in a dma_window. ?? do decrement cpu counters when in a dma_window. 30 cpu_hrt_srt_enab le r/w 0 ?? controller will interpret that dma port contains only hard real time dma requests. ?? controller will interpret that dma port contains hard real time or soft real time dma requests. 29 blb_enable r/w 0 ?? disable back log buffer ?? enable back log buffer. 28 dyn_ratios r/w 0 ?? use static ratios. this means accounts are incremented by the value (ratio+ ddr burst size (in terms of cycles)) whenever a cpu ddr burst is performed. ?? enable dynamic ratios. this means accounts are incremented by the value ratio every clock cycle that is spent on servicing a cpu ddr burst. this feature also causes account not to decrement during clock cycles that are spent on cpu ddr bursts. 27:18 reserved r - these bits should be ignored when read, and written as 0s. table 9: register description bit symbol access value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-30 17:16 cpu_preempt 1 r/w 0x1 0x0: no preemption (once a cpu mtl command has started to enter the ddr arbitration buffer, it will go completely into the ddr arbitration buffer, uninterrupted by other (cpu or dma) mtl commands. 0x1: preempt a cpu mtl command when it started to enter the ddr arbitration buffer while inside of the dma window, and is currently active in the dma window. the cpu mtl command will only be interrupted by a dma mtl command, not by another cpu mtl command. 0x2: unde?ed 0x3: preempt a cpu mtl command that is currently active in the dma window (independent of when it started to enter the ddr arbitration buffer).the cpu mtl command will only be interrupted by a dma mtl command, not by another cpu mtl command. recommended value is 0. 15:2 unused r - these bits should be ignored when read, and written as 0s. 1:0 dma_preempt 2 r/w 0x1 0x0: no preemption (once a dma mtl command has started to enter the ddr arbitration buffer, it will go completely into the ddr arbitration buffer, uninterrupted by other (cpu or dma) mtl commands. 0x1: preempt a dma mtl command when it started to enter the ddr arbitration buffer while inside of the cpu window, and is currently active in the cpu window. the dma mtl command will only be interrupted by a cpu mtl command, not by another dma mtl command. 0x2: unde?ed 0x3: preempt a dma mtl command that is currently active in the cpu window (independent of when it started to enter the ddr arbitration buffer).the dma mtl command will only be interrupted by a cpu mtl command, not by another dma mtl command. if enabled recommended value is 3. 1 the preemption ?ld determines the aggressiveness with which mtl commands are preempted when they are active in a window that was not meant for the mtl command. value 0 represents low aggressiveness, value 0x1 represents medium aggressiveness, and value 0x3 represents high aggressiveness. the more aggressive, the better the time multiplexing by means of windows is accomplished. however, aggressive preemption may result in lower overall bandwidth. 2 see above footnote. offset 0x06 5184 arb_hrt_window 31:16 unused r - these bits should be ignored when read, and written as 0s. 15:0 window r/w 0x003f window size for hard real-time (hrt) mtl requests (in terms of clock cycles). add 1 for the real effective window size. offset 0x06 5188 arb_cpu_window 31:16 unused r - these bits should be ignored when read, and written as 0s. 15:0 window r/w 0x003f window for central processor unit (cpu) mtl requests (in terms of clock cycles). add 1 for the real effective window size offset 0x06 51c0 arb_cpu_limit 31:16 unused r - these bits should be ignored when read, and written as 0s. table 9: register description bit symbol access value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-31 15:0 limit r/w 0xffff when the ddr controller internal cpu account exceeds this value, no cpu ddr burst will be performed when dma traf? is present (cpu traf? has lower priority than dma traf?). the internal cpu account is decremented by decr every clock cycle. for increment information see dyn_ratios description. 1 see register arb_cpu_ratio for a description of the ratio value. 2 when transferring a burst of n 32-bit data elements at a double data rate, the burst size in terms of clock cycles is n/2. offset 0x06 51c4 arb_cpu_ratio 31:8 unused r - these bits should be ignored when read, and written as 0s. 7:0 ratio r/w 0x04 if dyn_ratios are disabled the value is added to the internal account for each cpu ddr burst. if dyn_ratios are enabled then this value is added to the internal account for each clock cycle spent on a cpu ddr burst. offset 0x06 51c8 arb_cpu_clip 31:16 reserved r - these bits should be ignored when read, and written as 0s. 15:0 clip r/w 0xffff cpu account clip. when the internal account goes above this value the cpu ddr bursts are ?or free? this value should always be equal or higher than limit. offset 0x06 51cc arb_cpu_decr 31:8 reserved r - these bits should be ignored when read, and written as 0s. 7:0 decr r/w 0x01 cpu account decrement. this value is used to decrement the internal account of each clock cycle (with some exceptions). performance measurement to allow for performance evaluation, the ddr sdram controller includes a set of registers that measures data traf?. incremental 32-bit counters are used to measure the read and write traf? on every mtl port separately. offset 0x06 5200 pf_mtl0_rd_valid 31:0 mtl_rd_valid r/w - counter for valid mtl read data elements. offset 0x06 5204 pf_mtl0_wr_accept 31:0 mtl_wr_accept r/w - counter for valid mtl write data elements. offset 0x06 5208 pf_mtl1_rd_valid 31:0 mtl_rd_valid r/w - counter for valid mtl read data elements. offset 0x06 520c pf_mtl1_wr_accept 31:0 mtl_wr_accept r/w - counter for valid mtl write data elements. offset 0x06 5240 pf_idle 31:0 idle r/w - counts cycles in which the ddr memory controller is considered to be idle (not valid entries on the top of the ddr arbitration queue). errors these registers can be used to observe ddr memory addressing errors. if an mtl command is referring to an address outside the ddr addressable region, the mtl command speci?s are registered in the error registers, and an interrupt to the tm3260 is raised to indicate the error. in the case of multiple successive errors, the mtl command that caused the ?st error is registered, but successive errors are not registered (until the valid ?ld of err_valid is set to ??. offset 0x06 5280 err_valid 31:1 unused r - these bits should be ignored when read, and written as 0s. table 9: register description bit symbol access value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 9: ddr controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 9-32 6. references [1] double data rate (ddr) sdram specification, jedec standard jesd79, june 2000, jedec solid state technology association [2] eia/jedec standard, stub series terminated logic for 2.5 volts (sstl_2), eia/jesd8-9, september 1998, electronic industries association, jedec solid state technology division 0 valid r/w 0x0 ?? no error ?? error this is used to acknowledge the interrupt error indication. offset 0x06 5284 err_mtl_port 31:2 unused r - these bits should be ignored when read, and written as 0s. 1:0 mtl_port r - mtl port that caused the error. offset 0x06 5288 err_mtl_cmd_addr 31:0 mtl_cmd_addr r - mtl command address. offset 0x06 528c err_mtl_cmd_read 31:1 unused r - these bits should be ignored when read, and written as 0s. 0 mtl_cmd_read r - mtl command read. offset 0x06 5290 err_mtl_cmd_id 31:10 unused r - these bits should be ignored when read, and written as 0s. 9:0 mtl_cmd_id r - mtl command identi?r. see section 2.2 on page 26- 2 for id codes. offset 0x06 5ffc module_id 31:16 module_id r 0x2031 ddr memory controller module id 15:12 major_rev r 1 major revision number 11:8 minor_rev r 1 minor revision number 7:0 aperture r 0 aperture size is 4 kb ((aperture+1)* 4 kb). table 9: register description bit symbol access value description
1. introduction the lcd controller is required to control the power sequencing of the lcd panel. all the other functions required for an lcd controller like color expansion, screen timing generation is taken care by the qvcp (quality video composition processor). qvcp also does some video enhancement functions. please refer to the qvcp documentation for the details about these functions. 1.1 lcd controller features the following feature allows pnx15xx series to be connected to many lcd models: automatic power on/off sequencing programmable delays for the power sequencing polarity control for power enable and back light control signals data enable signal generation 2. functional description 2.1 overview the lcd controller receives the parallel video out data from the qvcp along with the timing signals (hsync, vsync, cblank and clk_lcd) and applies power sequencing before sending it out to the lcd interface. it converts cblank signal into chapter 10: lcd controller pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 10: lcd controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 10-2 de as required by the lcd panel. apart from these timing signals, it also generates the power enable (tftvddon) and back light control (tftbklton) signals that are required for some lcds. figure 1 presents the lcd controller block diagram. 2.2 power sequencing lcds are very sensitive to the power sequencing. not following these rules may create a latch-up or dc effect that would damage the lcd panel. figure 2 pictures the generic power sequence constraints. at power up of the system, the lcd panel remains without any power supply applied. the lcd controller provides a signal, tftvddon, to power the lcd panel. there is some constraint on the ramping up of the power supply (time constraint t1 ). but this time constraint is board related and hence the lcd controller does not provide any support. once the power is stable, the data/control signals (data/hsync/vsync/ dataenable) may be driven after t2 (before the tft power supply is on, the data/ control signals must be at 0 v). after the data/control signals have become valid, a minimum time, t3 , is required before the backlight of the panel can be turned on. figure 1: block diagram of the lcd controller 26-bit counter state machine lcd_setup_reg lcd_cntrl_reg gating logic vsync_in hsync_in cblank_in data_in q v c p i/f vsync_tft de_tft tftvddon tftbklton hsync_tft data_tft figure 2: generic power sequence for tft lcd panels t1 t2 t3 t4 t5 t6 tftvddon signals tftbklton valid
philips semiconductors pnx15xx series volume 1 of 1 chapter 10: lcd controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 10-3 similar power sequence applies for the power down sequence, resulting in the de?ed t4 and t5 parameters. after a power down sequence is completed, a minimum time, t6 , is necessary before the next power up sequence can be started. these delay values, t2, t3, t4, t5, and t6, are programmable in the lcd controller. 3. operation 3.1 overview after reset, an initialization program (like an lcd driver) sets up the values in the lcd_setup register. this register is used to enable the lcd interface and to specify the power sequencing delay values needed for the particular lcd panel. refer to section 4. on page 10- 6 for the mmio register layout details. this register is implemented as a ?rite once?register to prevent a software application from changing the delay values after the initialization program has set the correct values. programming incorrect values may damage the lcd panel. when the software is ready to send data to the lcd panel, it sets start_pud_seq bit in the lcd_control register. this starts the power up sequencing. similarly, when the software wants to shut down the lcd panel, it resets the bit. this starts the power down sequencing. the power sequencing is controlled by a state machine to guaranty all the critical timing parameters. 3.2 power sequencing state machine the state machine in the lcd controller generates the control signals to gate the data/control signals for the lcd interface. on reset these signals are de-asserted so that the lcd interface is disabled. once the power up sequence is started, these signals are asserted in the order required for the power up sequence. the delays are
philips semiconductors pnx15xx series volume 1 of 1 chapter 10: lcd controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 10-4 calculated using a 26-bit counter that is controlled by the state machine. this counter runs on the 27 mhz clock (the input pnx15xx series crystal). the state machine is shown in figure 3 . 3.2.1 idle state after reset, the state machine comes up in the idle state. in this state, when the lcd_enbl signal (which is asserted when both lcd_if_en and start_pud_seq bits are set) is asserted, the power up sequence is started by asserting the tftvddon signal and loading the counter with pwren_dce_delay that is set in the lcd_setup register. the counter starts to count down after it is loaded. if the lcd_enbl is de-asserted in the idle state, then the state machine goes to the peped state, de-asserts the tftvddon signal and loads the counter with pwr_en_pwren_delay value. if the lcd_enbl is still asserted when the counter decrements to zero, then the state machine goes to dcen state and asserts the ?ce?signal. it also loads the counter with dce_bklt_delay value. 3.2.2 dcen state in the dcen state, when the counter reaches zero and lcd_enbl is still asserted, then the state machine transitions to the blen state and asserts the tftbklton signal. this completes the power up sequence. if the lcd_enbl signal is de-asserted when ?ce?signal is still asserted, then the ?ce signal is de-asserted and the counter is loaded with dce_pwren_delay value. there is no state transition. if the counter reaches zero with both the dce and lcd_enbl signal de-asserted, the state machine transitions to the peped state. during this transition, the tftvddon signal is de-asserted and the counter is loaded with pwren_pwren_delay value. figure 3: power sequencing state machine block diagram idle dcen peped blen lcd_enb l && cnt_done lcd_enbl_neg lcd_enbl && cnt_done !lcd_enbl && cnt_done && !dce !lcd_enbl && cnt_done cnt_done
philips semiconductors pnx15xx series volume 1 of 1 chapter 10: lcd controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 10-5 3.2.3 blen state in the blen state, when the lcd_enbl signal is de-asserted, the tftbklton signal is de-asserted and the counter is loaded with bklt_dce_delay value. there is no state transition. when the counter reaches zero with lcd_enbl signal still de-asserted, the state machine moves to the dcen state de-asserting the dce signal. during this transition, the counter is loaded with dce_pwren_delay value. if the lcd_enbl signal is asserted in the blen state, the tftbklton signal is asserted and there is no state change. 3.2.4 peped state in the peped state, the state machine waits for the counter to reach zero to force the pwren_pwren_delay and goes back to the idle state. this completes the power down sequencing. if the lcd_enbl signal is asserted when the counter reaches zero, a new power up sequencing is started. 3.3 counter the counter used to calculate the delays is a 26-bit down counter. it starts counting down as soon as it is loaded with a delay value and asserts the cnt_done signal when the counter reaches zero. it runs on the 27 mhz clock (input pnx15xx series crystal). 3.4 gating logic the control signals from the state machine are in the clk_lcd_tstamp clock domain. they are ?st synchronized to the clk_lcd clock domain before using them to gate the data/control signals from the qvcp. the clk_lcd clock is also gated without any glitch in the gating logic. the clock gating circuit is shown in figure 4 . figure 4: clock gating logic dce_sync clk_lcd clk_lcd_out
philips semiconductors pnx15xx series volume 1 of 1 chapter 10: lcd controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 10-6 4. register descriptions a summary of the lcd controller mmio register is presented in t ab le 1 and the layout of the mmio registers is described in section 4.1 . table 1: lcd controller register summary offset name description 0x07,3000 lcd_setup supports programmable delay for the power sequencing. 0x07,3004 lcd_cntrl control register to start the power on/off sequencing. 0x07,3008 lcd_status gives the status of power up/down sequencing. 0x07,300c?7,3ff0 reserved 0x07,3ff4 lcd_disable_if to disable the mmio interface for power management. 0x07,3ff8 reserved 0x07,3ffc lcd_module_id module id number, including major and minor revision levels.
philips semiconductors pnx15xx series volume 1 of 1 chapter 10: lcd controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 10-7 4.1 lcd mmio registers table 2: lcd controller registers bit symbol acces s value description offset 0x07,3000 lcd_setup note 1: this is a special register with respect to write. this is a ?rite once register. it is implemented this way to prevent a software application from altering the delay values after the setup software initialized them correctly. this protects the lcd panel from being damaged by an incorrect write by a software application. even if default values are desired, do a write to the register so that the write-once protection mechanism takes effect . note 2: the delay values are based on a 27 mhz clock. note 3: please refer to figure 22-2 to correlate the delay values. 31 lcd_if_en r/w1 1 this bit enables the lcd interface. if this bit is set, then power sequencing will be applied to the data/control signals based on the value of start_pud_seq bit in lcd_cntrl register. if this bit is not set, then all the lcd interface signals will remain de-asserted. when this bit is set, the output router block will select the lcd interface overriding any other programming of the mux in the output router. 30 vdd_pol r/w1 1 1 = tftvddon is of positive polarity. 0 = tftvddon is of negative polarity. 29 bklt_pol r/w1 1 1 = tftbklton is of positive polarity. 0 = tftbklton is of negative polarity. 28:20 unused - - 19:16 pwren_pwren_del ay r/w1 11 delay from the end of a power down sequence to the start of the next power up sequence. delay value t6 in steps of 100 ms with 0 corresponding to 100 ms and 15 corresponding to 1600 ms. 15:12 dce_pwren_delay r/w1 3 delay from data/control signals de-assertion to the de-assertion of tftvddon signal. delay value t5 in steps of 10 ms with 0 corresponding to 10 ms and 15 corresponding to 160 ms. 11:8 bklt_dce_delay r/w1 7 delay from de-assertion of tftbklt signal to the de-assertion of data/control signals. delay value t4 in steps of 100 ms with 0 corresponding to 100 ms and 15 corresponding to 1600 ms. 7:4 dce_bklt_delay r/w1 2 delay from assertion of data/control signals to tftbklt signal assertion. delay value t3 in steps of 100 ms with 0 corresponding to 100 ms and 15 corresponding to 1600 ms. 3:0 pwren_dce_delay r/w1 3 delay from assertion of tftvddon signal to assertion of data/ control signals. delay value t2 in steps of 10 ms with 0 corresponding to 10 ms and 15 corresponding to 160 ms. offset 0x07,3004 lcd_cntrl note: a board level power sequencing must also be observed to ensure that the lcd panel is powered and ready to accept the power-up sequence before the power-up sequence is started from pnx15xx series. 31:1 unused - - 0 start_pud_seq r/w 0 writing a 1 (when the bit is 0) will start a power up sequencing and writing a 0 (when the bit is 1) will start a power down sequencing. when the lcd interface is not enabled, this bit always stays 0. offset 0x07,3008 lcd_status 31:1 unused - -
philips semiconductors pnx15xx series volume 1 of 1 chapter 10: lcd controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 10-8 0 pud_status r 1 this is a read only bit that gives the status of power up or down sequence, if this bit is set to ??and start_pud_seq bit is ?? then the power up sequence has been completed. if this bit is set to ? and start_pud_seq bit is ?? then the power down sequence has been completed. if this bit is ?? then either a power up or down (depending on start_pud_seq bit) sequence is in progress. offset 0x07,300c?x07,3ff0 reserved offset 0x07,3ff4 lcd_disable_if 31:1 unused - 0 disable_if r/w 0 setting this bit to ??disables the mmio interface. the only valid transactions are to the interface disable register. all other transactions are not valid, write transactions will generate a write error and read transactions will return 0xdeadabba. the bit is used to provide power control status for system software power management. offset 0x07,3ff8 reserved offset 0x07,3ffc lcd_module_id 31:16 id r 0xa050 module id. this ?ld identi?s the module as the lcd controller. 15:12 maj_rev r 0x0 major revision id. this ?ld is incremented by 1 when changes introduced in the module result in software incompatibility with the previous version of the module. first version default = 0. 11:8 min_rev r 0x0 minor revision id. this ?ld is incremented by 1 when changes introduced in the module result in software compatibility with the previous version of the module. first version default = 0. 7:0 aperture r 0x00 aperture size. identi?s the mmio aperture size in units of 4 kb for the lcdc module. lcdc has an mmio aperture size of 4 kb. table 2: lcd controller registers ?ontinued bit symbol acces s value description
1. introduction the qvcp (quality video composition processor) is a high-resolution image composition and processing pipeline that facilitates both graphics and video processing. in combination with several other modules, it provides a new generation of graphics and video capability, far exceeding the older standards. qvcp provides its advanced functionality using a series of layers and mixers; a series of display-data layers (pixel streams) are created and logically mixed in sequence to render the composite output picture. the pnx15xx series hosts one qvcp module. the display processor (qvcp) contains a total number of two layers and is mainly intended to be connected to a tv, a monitor or an lcd panel. due to the independence of the layers, a number of different scenarios is possible. however, in general, the qvcp has been designed to mix one video plane and one graphic plane. it can therefore be used to display a fully composited video image consisting of pip(s), menu(s), and other graphical information. in this document, the words surface or plane are used to replace layer depending on the context. qvcp supports a whole range of progressive and interlaced display standards: for televisions, from standard-de?ition resolutions such as pal or ntsc to all eighteen atsc display formats such as 1080i or 720p, and for computer and lcd displays, from vga to w-xga resolutions at 60 hz. the wide variety of output modes guarantees the compatibility with most display-processor chips. in order to achieve high-quality video and graphics as demanded by future consumer products, a number of complex tasks need to be performed by the qvcp. the main functions of the video and graphics output pipeline are listed below: fetching of up to two image surfaces from memory color expansion in case of non-full color or indexed data formats reverse-gamma correction video quality enhancement such as luminance sharpening, chroma transient improvement, histogram modi?ation, skin-tone correction, blue stretch, and green enhancement. horizontal up-scaling for video and graphics images in both linear and panorama mode. chapter 11: qvcp pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-2 screen timing generation adopted to the connected display requirements (sd-tv standards, hd-tv standards, progressive and interlaced formats) color space uniqueness of all the display surfaces merging of the image surfaces (blend, invert, exchange) positioning of the various surfaces (including ?er positioning) brightness and contrast control on a per-surface basis gamma correction and noise shaping of the ?al composited image output format generation 1.1 features qvcp comprises various processing layers , a hierarchical mixer cascade (where an image surface is always associated with a layer and a mixer structure), and an output pipeline . a top-level block diagram is shown in figure 1 . a layer contains various video and graphics processing functions (which are necessary to accomplish the tasks mentioned above) and obtains data from a particular data source. the data may provide a desktop image, a motion video image, a cursor, or a sprite image. registers in the layer select the data source and set the display and the image-processing parameters. a mixer is a functional block that selects between and manipulates data streams from two sources: the pixel stream from its companion layer and the pixel stream output of the previous mixer (in the hierarchy). the mixing functions include pixel inversion, pixel selection (between sources), and alpha blending. the mixers operate on a per- pixel basis using programmable logical raster operations (rops) to determine which figure 1: qvcp top level diagram layer structure mixer output pipeline programming and screen timming control vbi data dma interface to main memory dma1 dma2 dma3 dma4 mmio interface layer1 layer2 mixer_out
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-3 functions to apply. the keys used in the raster operations include chroma keying (color-keying on a color range) and color keying. the output of the mixer is a continuous stream of pixels at the video-clock rate going to the display device. the output of the mixer hierarchy is connected to the output pipeline . the output pipeline comprises gamma correction, dithering (noise shaping), and reformatting. the formatter inserts vbi data in the horizontal blanking interval and re-formats the ?al output-data stream according to the requirements of the connected device.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-4 2. functional description 2.1 qvcp block diagram figure 2: qvcp block diagram pfu ckey/ udth cups 8 10 lint vcbm 10 fcu lcu data data 10 layer data layer data layer data layer mix layer mix stg layer cdns 444:422 intl frmt omux data oif_progreg data data dma ctrl stgl_progreg poolselect dma interface out_if prog_if imux pbus mmio interconnect clut pr_mux layer data layer data poolselect/layerassign pr_clut lshr pr_mux layer data layer data poolselect/layerassign pr_lshr cftr pr_mux laye r data layer data poolselect/layerassign pr_cftr hist pr_mux layer data layer data poolselect/layerassign pr_hist layerassign gnsh dither/ reformat hsru pr_mux layer data layer data poolselect/layerassign pr_hsru dcti pr_mux layer data layer data poolselect/layerassign pr_dcti pr_mux layer data poolselect/layerassign dma ctrl data data pr_dma semi planar
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-5 the basic block diagram of the qvcp is illustrated in figure 2 . the front-end part accommodates 2 symmetrical layers, which suggest 2 image surfaces with independent characteristics such as pixel data format, color space, size and position on the ?al composite image. each of these layers is tied into the memory access infrastructure of the pnx15xx series via an independent dma read interface. a layer (or a layer module, as it is called) is responsible for producing a valid pixel for every display coordinate. both layer modules, as mentioned before, are identical, and so, there are no restrictions as to how each layer may be utilized: 2 video layers, 2 graphics layers, or 1 graphic + 1 video layer are examples of some of the combinations that can be achieved. however, as described later, there are some restrictions on the image improvements that can be applied per surface. a wide variety of rgb, yuv, and alpha blend formats are supported. each layer, as detailed later, can perform a variety of video-processing functions such as color space conversion, 4:4:4 to 4:2:2 down-?tering and 4:2:2 to 4:4:4 up-sampling, color- and chroma key extraction, etc. it should be noted that ?egion-based graphics?is not supported at the hardware level; software must generate one uniform color depth surface if an application requires region based graphics. 2.2 architecture the qvcp is architected using the concept of virtual identical layers with a common resource pool . each layer is built as a skeleton which contains only the essentialprocessing blocks. the remaining processing blocks --- the more exotic ones responsible for picture enhancement, for example --- are part of the pool resources.the principal assumption, in de?ing the qvcp architecture, is that there is no use-case which requires all of the features to be active in all of the layers at the same time. for any particular use-case, there will be a speci? selection of features required in each layer. all layers can make use of pool resources. there is no speci? order or assignment of the pool resources to the speci? layers. however, prior to using qvcp in the context of a speci? application scenario, it is required to assign resources from the pool to speci? layers. this is done via a set of global qvcp resource-allocation registers. in addition to the symmetric layer structure, the qvcp contains, as mentioned before, a set of (special) image processing functions which are located outside of the layers in a resource pool. the pool-resource concept takes into account the fact that software drivers would like to access the layers in a symmetrical uni?d fashion. the features used in a certain display scenario are however not symmetrically distributed among the layers at all. for a given application scenario, there is no case when every layer uses all its resources. therefore theses features which are never used by all layers at the same time are located in the resource pool. hence, the pool contains only a number of functional units of the same kind which is smaller than the total number of layers. attached to each layer is a mixer which acts as a three-port image combination module, combining the image coming from the layer attached to the mixer with the image coming from the previous mixer. the resultant image is forwarded to the next mixer. this mixer cascade implies a certain layer, and therefore a certain image, order on the ?al display surface.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-6 the outputs of all mixers are connected to the back-end part of the qvcp --- the output formatter. the output formatter performs all necessary functions to adopt the ?al composited image to the display requirements. among the functions performed in the output formatter are: gamma correction, chrominance downsampling, output formatting, and vbi insertion. 2.3 layer resources and functions this section focuses on the elements comprising a layer. note that all of the described modules are present in each layer exactly once, the justi?ation being that they (elements) are either always needed for the basic operation of a layer or they are so small (in design size) that assigning them to the resource pool would be inef?ient due to the multiplexing and routing overhead associated with the pool elements. 2.3.1 memory access control (dma ctrl) qvcp has 4 dma agents, each of which connects to a 512-byte buffer in the dma adapter. dma agents 1-2 are hard coded to layer1-2 respectively. dma4 is used to fetch a vbi packet or a data packet for dma-based control-register programming. dma3 can be assigned to any of the two layers for supporting the semi-planar input format. for video data fetches, the request block size is equal to the initial layer width (before horizontal scaling). if start_fetch is disabled (i.e., enable bit 31 of register 0x10e2c8 is programmed to zero), the ?st dma request starts right after the layer_enable is asserted and qvcp works as if prefetch is enabled. however, if start_fetch is enabled (i.e., enable bit 31 of register 0x10e2c8 is programmed to one), then the dma starts fetching only when qvcp s internal line counter reaches the 12-bit line threshold programmed in the fetch start bits [11:0] of register 0x10e2c8. data fetched for the ?st ?ld (interlaced) or frame (progressive) is not used and is ?shed at the fcu (flow control unit) fifo. thereafter, the pixels for the second ?ld/frame start marching into the fcu fifo, waiting for the correct layer position. the fcu fifo releases pixels only if the x,y coordinates generated by the screen timing generator (stg) match the layer position. in case of an interlaced output, the ?ld id is also checked. the dma fetch request for the next active video line starts as soon as the last active pixel of the current line moves from the adapter fifo into the processing pipeline and this request must be served in time to guarantee that the ?st active pixel of this new line is ready at the fcu fifo before the stg signals the start of active video for the new line. the dma-based register-control programming only needs to be done once for a particular display scenario; thus, dma4 is mainly used for vbi data fetch. qvcp is designed such that a vbi packet will only be inserted in the horizontal blanking interval and only one vbi packet is allowed in any one horizontal blanking interval. to insert this packet, there are two dma requests. the ?st request has a block size of 1 since it is used to fetch only the header (which contains the size information). the second request is meant to fetch actual data of the required size and so, the maximum dma request size (for the second request) is equal the length of horizontal blanking interval. the vbi data for the current horizontal blanking interval is always fetched in advance and stored in the dma buffer (in the adapter). after sending out this prefetched data, the vbi dma control unit (dma4) requests a prefetch of the next packet (and correct operation requires that the sequence of the next two fetches must
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-7 complete before the start of the next horizontal blanking interval). in the current design, the vbi packet can be inserted only between the eav and the sav time codes. 2.3.2 pixel formatter unit (pfu) the pfu retrieves the raw data stream, for a particular image source, from the system memory and formats it according to the speci?d pixel format. t ab le 1 summarizes the various native pixel formats supported by the pfu. remark: semiplanar yuv 4:2:0 is supported by the software api. however the support is achieved by duplicating the uv samples. therefore it is not a true 4:2:0 support. true 4:2:0 support can be achived by using the mbs module to convert the 4:2:0 pixels into 4:2:2 or 4:4:4 pixels before entering qvcp. remark: the pfu does not do the pixel conversion it just formats properly the raw data into the qvcp pipeline, therefore it requires to know the input pixel format. 2.3.3 chroma key and undither (ckey/udth) unit chroma keying allows overlaying of video and/or graphic layers, depending on whether the considered pixel lies within a speci?d color range. this feature allows video transparency or ?reen screening??a technique used for compositing a foreground imagery with a background. undithering allows recovery of 9 bits of precision from the dithered 8 bits stored in memory (where qvcp fetches the pixels for video processing). ckey chroma key matching is usually performed on a range of values rather than on a single value as in color keying; a key mask is provided to allow chroma keying on speci? bits within the data word considered. in qvcp, the color key is generated in each layer in the source color space. every layer can use up to four color keys. table 1: summary of native pixel formats format description 1 bpp indexed clut entry = 24-b color + 8-b alpha 2 bpp indexed clut entry = 24-b color + 8-b alpha 4 bpp indexed clut entry = 24-b color + 8-b alpha 8 bpp indexed clut entry = 24-b color + 8-b alpha rgba 444 16-b unit, containing 1 pixel with alpha rgba 4534 16-b unit, containing 1 pixel with alpha rgb565 16-b unit, containing 1 pixel, no alpha rgba 8888 32-b unit, containing 1 pixel with alpha packed yuva 4:4:4 32-b unit, containing 1 pixel with alpha packed yuv 4:2:2 (uyvy) 16-b unit, 2 successive units contain 2 horizontally-adjacent pixels, no alpha packed yuv 4:2:2 (yuy2, 2vuy) 16-b unit, 2 successive units contain 2 horizontally-adjacent pixels, no alpha semiplanar yuv 4:2:2 separate memory planes for y and uv (both 8 and 10 bpp)
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-8 chroma keying allows overlaying video depending on whether the pixel lies within a range of color values. this feature allows video transparency or ?reen screeninga technique for compositing foreground imagery with a background. color keying is considered to be a subset of chroma keying and can be achieved by setting the color range accordingly; because of the similarity between chroma and color keying (the difference being a color range instead of a ?ed single color), this document will use the terms interchangeably, even though qvcp implements both functionality. the chroma/color key result is used for mixing functions downstream. for example, color keying can be used to determine which pixels should contain motion video. the color key function will compare the pixels of a layer with the color key register and place motion video from another layer in those pixels that match. the color key is generated in each layer (before color space conversion). each byte lane of the expanded rgb 8:8:8 or yuv 4:4:4 new pixel is passed through an 8-bit color key and mask. (for the yuv 4:2:2 input format, the u and v samples are repeated for every other pixel). the result in each channel is compared to the register values for color key lower range and color key upper range. every layer can use up to four color keys. when the pixel component is equal to a range register value or is within the range, the result of the comparison for that byte lane is true (1). if its outside the range, the result is 0. the results from the three byte lanes are used as keys in the 8-bit color key combining rop. this rop is a mechanism used for extreme ?xibility in keying and is located in the layer. (it is not to be confused with rop in the mixer which follows each layer.) cnkey0_layer is determined by checking if the b(v) color component is within the chroma key range. cnkey1_layer is determined by checking if the g(u) color component is within the chroma key range. cnkey2_layer is determined by checking if the r(y) color component is within the chroma key range. cn represents one of the four possible key colors. since four colors are possible per layer, four different rops exist for determining which component of which key color should lead to a color key hit. if the color component is within the range, the key is set to 1. if its not, the key is set to 0. table 2: color key combining rops rop bit key2 key1 key0 [0] 0 0 0 [1] 0 0 1 [2] 0 1 0 [3] 0 1 1 [4] 1 0 0 [5] 1 0 1 [6] 1 1 0 [7] 1 1 1
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-9 the rop should be programmed to enable each key combination for which one wants to trigger a ?olor key=true. for each pixel in the stream, the rop checks the keys to determine if they match one of the selected combinations. when there is a match, the result is true (1). if there is no match, the result is false (0). the result of the color key combining rops is combined in the mixer and used as a key (key1) in the invert, pixel select, alpha blend select and pass through key rops. the examples in t ab le 3 describe how to program the rop for various results. the result of the four rops within a layer is fed into the mixer associated with the layer. the four keys are called: current_color_key_0-3. udth udth is the undither unit that is used to recover 9 bits of precision from an 8-bit dithered data. it is the reverse of the dither operation in the vip as an 8-bit-wide video is usually not very practical (since some head room is lost because there is not a good automatic gain control). for quality reasons, therefore, one has to process 9 or 10-bit video. however, if every stage in the processing chain?fter its required processing?as to round to 8 bits, accumulated quantization errors (quantization noise) occurs. the local video data paths can be made wider (e.g., 10 bits), but since there are only 8-bit wide ?ld memories, compression from 9 bits or more to 8 bits or less will have to take place. furthermore, if pixels are blindly rounded and/or quantized to 8 bits, particularly for low-frequency (small) signals, the quantization noise is not evenly distributed but remains correlated to the input signal, and contouring effects occur. so, what is wanted is 9-bit video quality for an 8-bit (memory) price. with this goal in mind, it is primarily to de-correlate the quantization error and also to retain some precision, that dithering is used. dithering distributes the error across the entire spectrum simply by adding some random noise prior to quantization via a random or semi-random perturbation of the pixel values. the 8-bit values, with 9-bit precision, are stored in memory where they are fetched from and processed by the qvcp. for the part of a picture that is almost constant (or ?t) in the horizontal direction, one should try to recover the full 9 bits from the stored 8 bits because the quantization error is more noticeable; however, when there are more high-frequency components, the full 9 bits cannot be recovered, but the quantization error is less visible anyway. table 3: chroma key rop examples rop description 0xff all rop bits are enabled, so all of the key combinations are included. one of them must be true; therefore, the result will always be true (chroma key=1). 0x00 none of the rop bits is enabled, so the rop will never get a match. the result will always be false (chroma key=0). 0x80 bit 7 is enabled. this is the combination where all three keys=1. the result will be true only when all the pixels yuv (rgb) are in the yuv (rgb) chroma key range. 0xf0 bits 7,6,5 and 4 are enabled. these are the combinations where key2=1. for any pixel where the y(r) component (key2) matches the chroma key range, the rop result will be 1. 0xe8 bits 7, 6, 5, and 3 are enabled (11101000=e8). these are the combinations where at least two of the keys are true. in this case, the rop will return true whenever any two of the color components match their respective chroma key range.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-10 the udth unit, however, does more than just undithering. it does format conversion as well. qvcp has its own data format protocol (10-bit signed data -- up(y/r), mi(u/ g), lo(v/b) --- and 8-bit unsigned alpha) and is designed to process data with a nominal range of 9 bits; one extra bit is reserved for overshoots and undershoots. input data gets converted, from an external format to the native qvcp format, inside the udth module. figure 3 shows the data-?w diagram of the udth unit. in the ?ure, the nominal data range is shown for each conversion step for both 8- (bottom part) and 10- (top part) bit inputs. note that an 8-bit input to qvcp will be converted to a 9+1 format by undithering or by left shifting. a 10-bit input, however, can be either true 10 bits or 9+1 bits; for the former, there is not too much head-room left and so, the nominal range of the various layers should be equalized at the vcbm unit. the function of alpha processing unit is to insert a ?ed alpha or pre-multiply each pixel with a per-pixel alpha. for a 10-bit input, only ?ed alpha is supported. figure 3: undithering and pedestal manipulation unsigned to signed conversion nominal range increasing by 2 sign extension of the msb bit pedestal removing 8bu 8bs 9bs 10bs 10bs format left shift by 1 add 0 to lsb position append 2nd mbs to lsb position undither increasing nominal range by 2 or or 8bs 9bs 16~235 -112~107 -224~214 -224~214 if pedestal substraction is on -256~182 else -224~214 nominal data range for 8bits input reconstruct 10bit data from u/m/l path and alpha path 8msb 2lsb u/m/l (8 bit) alpha (2 bit) clip -512 ~511 alpha processing nominal data range for 9+1 bits input 288~726 -224~214 -224~214 if pedestal substraction is on -256~182 else -224~214 nominal data range for 10 bits input 64~940 -448~428 -448~428 if pedestal substraction is on -512~364 else -448~428 format 10bu 10bs 10bs 10bs 10 bits input 8 bits input for true 10bits input, pedestal substraction is recommended off, the different nominal ranges for various layers could be equalized at the vcbm unit.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-11 2.3.4 chroma upsample filter (cups) the chroma (chrominance) upsampling module allows conversion of yuv 4:2:2 data streams to 4:4:4 data streams by interpolating the missing chrominance information. there exist two forms of 4:2:2 co-sited and interspersed. it depends on how the u&v data was down-sampled from 4:4:4 to 4:2:2. since both co-sited and interspersed 4:2:2 formats (as shown in figure 4 ) are supported, the up-sampling method of cups should be adapted accordingly. this feature is necessary for supporting rgb/ yuv outputs in full-color resolution. 2.3.5 linear interpolator (lint) the linear interpolator is used for horizontal up-scaling of graphics images. it is speci?ally used for graphics images because its nature makes it unsuitable for quality scaling of video material. however, due to its small size, the block is present in both layers of qvcp. this unit supports up-scaling only, and can handle both yuv and rgb data streams. it also supports scaling of the alpha channel as well as any potential previously-extracted color keys. the output samples are calculated from the input samples via a piece-wise linear interpolator. all pixel components are treated equally. remark: layer size (final)) register has to be updated to match the scaled width, if lint scaling is changed. 2.3.6 video/graphics contrast brightness matrix (vcbm) the ?st purpose of vcbm is contrast (gain) and brightness (offset) control (in that order). the contrast and brightness controls are for normalizing the amplitude (black and white level) of all sources. they also permit balancing the visibility of all video and graphics layers. an important bene? of having separate controls for all video and graphics layers is that the user interface never needs to disappear, even if the user tries to make (the video part of) the picture invisible. this bene? should be achieved by control software: limit the control range for the user interface layers. figure 4: 4:2:2 and 4:4:4 formats chroma (u, v) samples luma, alpha (y, a) samples interspersed co-sited (u0, v0) (u2, v2) (u4, v4) (u6, v6) (u0, v0) (u2, v2) (u4, v4) (u6, v6) chroma (u, v) samples luma (y) samples first luma, alpha samples in each line (y0, a0) (u0, v0) (u2, v2) (u4, v4) (u6, v6) (u1, v1) (u3, v3) (u5, v5) (u7, v7) 4:4:4 output 4:2:2 input
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-12 the second function of the vcbm unit is to take yuv (for video) or rgb (for graphics) inputs and produce rgb or yuv outputs. the color space conversion is effected by multiplying a 3x1column vector (with 3 components: y, u, v or r, g, b) in the source color space with a 3x3 matrix (of coef?ients) in order to obtain a 3x1 column vector in the destination color space. the programmable coef?ients of the 3x3 matrix can be altered to modify contrast, saturation, and hue. (10) where up, mi, and lo = r,g,b or y,u,v cij= the standard matrix coef?ients multiplied by the desired contrast ratio b = the brightness value divided by the desired contrast ratio for yuv input b?= 0 and for rgb input b?b for rgb -> rgb, there is no support for brightness control. thus, the main functions performed by the vcbm unit are: contrast and brightness control and color-space conversion with white-point control; this is achieved by using one or more operations from the following sequence: contrast control by multiplying the 9 matrix coef?ients by the same desired contrast ratio (where a ratio of 1 means a gain of unity). brightness control on yuv (add offset "b", as shown above, to values at the input of matrix, where b signi?s the desired brightness offset scaled by the contrast gain) yuv-to-rgb matrix, also usable for yuv-to-yuv optional saturation control via the yuv-to-rgb (etc.) matrix (by adjusting the contribution of u and v by the same ratio, while keeping the contribution of y as constant, done by modifying the six matrix coef?ients for u and v. optional white-d control via the yuv-to-rgb (etc.) matrix offset addition for making unsigned u&v guaranteed hard-clipping to 10-bit unsigned formats 2.3.7 layer and fetch control the layer fetch control receives the global screen coordinates from the stg and takes care of extracting the pixels from a layer when needed (i.e., when the programmed position for the layer has reached). another task (of the layer fetch control unit) is to clip layers exceeding the screen coordinates. up out mi out lo out c 00 c 01 c 02 c 10 c 11 c 12 c 20 c 21 c 22 up in b + mi in b + lo in b + =
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-13 2.4 pool resources and functions the following sections describe the pool elements. these elements are never needed in all of the layers at the same time. all of the pool units comprise three basic sub-modules (and so do the layer units): functional unit : this is where the data is processed. it contains the data path and the logic to control the ?w of data. register file : the register ?e contains the registers which are used to control the pool resource. these registers are programmed via the pbus and are read/write. push-pull interface : this unit is used to control the ?w of data into and out of the pool resource. the push pull interface allow the ?w of data to be stalled by and block in the video pipe. if a stall occurs then all processing of the inputs stops and all data is stored. when the stall is released then the data is processed as before. 2.4.1 clut (color look up table) the resource pool contains one set of component-based color-look-up tables for each color component and for the potential alpha value of a pixel. the look-up table has a depth of 256 words, with each word being 8 bits wide. the basic function of a clut is to expand indexed-color formats. an 8-bit indexed color would be applied to all component luts as an address, whereby each of the luts will provide on its data ports the previously-programmed data word belonging to that address. however, since the addresses of the luts are not linked together, gamma correction on a component basis is also possible. 2.4.2 dcti (digital chroma/color transient improvement) the digital color transient improvement (dcti) block improves the steepness of color transients. it is a form of delay modulation: around transients the signal is time- compressed. this is a non-linear operation, and it increases the bandwidth of the color signal. dcti can not increase the number of transients per line (that would require real bandwidth in the signal path), it can only increase the steepness of transients that are already there. dcti modi?s the u & v data paths. horizontal transients are detected and enhanced (without overshoots) by shifting the color values the amount of color shift is controlled by values generated via differentiating the original signal, taking absolute values of the differential, and differentiating the absolute values once again. to prevent the third harmonic distortion, the so-called over the hill protection is applied. this prevents peak signals from being distorted. 2.4.3 hsru (horizontal sample rate upconverter) the main purpose of hsru is horizontal up-sampling, where the re-sampling function obeys a third-order difference equation for the phase of the sample positions. this creates more space in the spectrum for lti to ?l. this extra room can also be used by other non-linear operations, like hist and vcbm, so that they will create less undesired aliasing. up-sampling is good before any non-linear operation, and all blocks behind the hsru will run on the higher sample-rate. we can also choose to up-sample the left and right edges of the image more than the centre. this is called
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-14 "panorama mode" or "superwide mode", and it is recommended for showing 4:3 or 14:9 images on a 16:9 display. besides a linear constant upscaling ratio, the hsru also supports special non-linear upscaling ratios for the panorama mode. remark: layer size(final) register has to be updated to match the scaled output size of hsru 2.4.4 hist (histogram modi?ation) unit the histogram modi?ation block complements the histogram measurement blocks in the mbs. it modi?s the y, u & v data according to a non-linear transfer curve. the y transfer curve is described by the 32 values of a look up table. the color difference signals are also coupled to this curve by a calculation derived from the original y and its value after the histogram modi?ation. the ?al aim is to provide a greater contrast by increasing the range of intensities in the input signal. 2.4.5 lshr (luminance/luma sharpening) unit the lshr module is used to improve (increase) the sharpness impression. inputs to the lshr unit are all three of the y, u and v signals. they are 10 bit signed values (- 512 to 511 range). the lshr unit modi?s the y component only; u and v remain untouched. outputs of the lshr unit are also 10-bit signed values. the lshr unit has a latency of 33 cycles when it is enabled. in the bypass mode, it has no latency. for proper operation, at least 7 dummy cycles are required between any two lines. the unit also performs sharpness measurements on the luma signal and the results are stored in two status register: lshr_e_max and lshr_e_sum. they are updated at the end of each frame. 2.4.6 color features (cftr) unit the color features block performs a sequential combination of three functions: skin tone correction blue stretch green enhancement these features are intended to correct the errors caused by the transmission and the phosphors used in crt displays. the reason that skin tone, blue-stretch (alters the white temperature) and green enhancement are chosen is that the human eye is most sensitive to unnatural errors in these colors. in practice, they can also be used to enhance the vividness of certain colors in the picture. skin tone correction will be useful to compensate for a small phase error in the demodulation of analog ntsc (hue error). blue stretch and green enhancement just look nice. remark: it may not be fully correct to state above that the color features are intended to correct the errors caused by the transmission and the phosphors used in crt displays. the real cause of the tint problem may well be that people are trying to correct for an error that no longer exists. the current practice in ntsc countries has been for a long time to encode for phosphors that are similar to ebu. if the tv makes no corrections for presumed original ntsc phosphors, then there will be no error.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-15 2.4.7 plan (semi planar dma) unit this pool element contains one dma channel which can be independently assigned to any layer. by default, this dma channels is assigned to the ?st layer. the dma channel is meant for fetching uv data in parallel to the fetching of y-data by the dma unit that is already present inside each layer. 2.5 screen timing generator the screen timing generator (stg) creates the required synchronization signals for the monitor or other display devices. the screen timing generator usually operates as the timing master in the system. however, it is also possible to synchronize the operation of the screen timing generator to external events i.e., a vertical synchronization signal. the screen timing generator also de?es the active display region. the coordinate system for the stg is (x, y), with (0, 0) referring to the top left of the screen. the coordinate (horizontal total, vertical total) de?es the bottom right of the screen. horizontal and vertical blanking intervals, synchronization signals, and the visible display are within these boundaries. some of the control parameters that need to be set for the screen timing are: htotal = total no. of pixels per line minus one vtotal = total no. of lines per ?ld minus one hsyncs/e = start/end pixel position of horizontal sync (hsync) vsyncs/e = start/end line position of vertical sync (vsync) hblnks/e = start/end pixel position of horizontal blanking interval vblnks/e = start/end line position of vertical blanking interval the following rules apply to the register settings specifying the screen timing using the above control parameters: total number of pixel per line: htotal + 1 total number of lines per ?ld: vtotal + 1 0,1 < hblnks <=htotal 0,1 < hsyncs <= htotal 0 < vblnks <= vtotal 0 < vsyncs <= vtotal hsync - must be asserted or negated for at least one clock vsync - must be asserted or negated for at least one scanline hblank - must be asserted or negated for at least two clocks vblank - must be asserted or negated for at least two scanlines
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-16 the state change of the odd_even signal is always tied to the rising edge of the vsync signal. figure 14 identi?s screen display parameters controlled by ?lds in the stg registers other restrictions for the screen timing generation are as follows: invalid hsyncs/e settings: 0, 1, 2 > htotal invalid hblnks/e settings: 0, 1, > htotal invalid vsyncs/e settings: 0, > vtotal invalid vblnks/e settings: 0, > vtotal invalid difference hsynce-hsyncs: -1 invalid difference hblnke-hblnks: 0, -1, -2 in interlaced modes these differences are not allowed:1, 2, 3, 4 to guarantee suf?iently long horizontal blanking: invalid difference vsynce-vsyncs: -1 invalid difference vblnke-vblnks: 0, -1, -2 invalid difference vblnke-vblnks: 0, -1, -2 2.6 mixer structure the properly formatted pixels from each layer are combined in a cascaded series of mixer units. there is one mixer unit associated with each layer unit within the qvcp. for a given screen position, each mixing unit can select the pixel from the layer, the pixel from the previous mixer, or a blend of the two pixels. if a layer does not generate a valid pixel for a speci? screen position, then the mixer will pass the pixel from the previous mixer. if no layers are producing valid pixels, a background color will be displayed. the mixer selection criteria are based on a number of functions rops that can be used to create such common effects as color keying. there are no restrictions on window size, position, or overlap. a mode such as pip is simple to implement by setting layer_n for full screen video and layer_n+1 to the pip. pip size and position may be changed on a frame by frame basis. effects such as blending a pip in and out of the full screen video are easy to achieve using the 256 level alpha blend capability of each mixer. the main functionality of the mixer stages is to compose the outgoing pixel streams from each layer to the ?al display image. the mixer data path operates on 10 bits. this includes clipping, alpha blending, inverting colors. which of those functions is applied and how, is de?ed in a set of raster operations (rops). a raster operation is always a logical combination of several input keys and a speci? rop register which enables one or more of the different key combinations. it (rop operation) is like a function that generates the output based on a logical combination of several input signals and the programmable rop register. each mixer knows 4 different keys (key0, key1, key2, key3) as illustrated in the mixer block diagram. key0, output key from previous layer, keypass rop
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-17 key1, (current color/chroma key pixel key or new pixel key 1) key2 (new pixel key 2) key3 color key of the previous pixel since each layer can have four color keys, the output is a 4-bit vector specifying which keys match the pixel. this 4-bit vector is masked by the colorkeymask. the result is key1. for key3 the procedure is similar, with the only difference being the color key vector is passed from the previous mixer. the result of masking the color key vector with the colorkeymask register is key3. however, one can do selective color keying for the current pixel. a colorkeyrop speci?s whether color keying is performed on the current layer pixel or not. inputs for this rop are key0,1,2, 3. the rop block decides if a certain operation is done on the pixel or not. the outputs of the select, alpha, invert, key_pass and alpha_pass rops are based on raster operations as shown in t ab le 4 . figure 5 illustrates the mixer function. the upper part shows the generation of the signals which are used to control the actual pixel manipulation functions shown in t ab le 4 . remark: for mixer 1 there is no previous mixer and therefore the corresponding inputs are set to 0. table 4: rop table for invert/select/alpha/keypass/alphapass rops rop bit key3 key2 key1 key0 00000 10001 20010 30011 40100 50101 60110 70111 81000 91001 101010 111011 121100 131101 141110 151111
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-18 2.6.1 key generation figure 5: mixer block diagram?ixel selection current_chroma_key_0 current_chroma_key_1 current_chroma_key_2 current_chroma_key_3 1 new_pixel_key1 key1 new_pixel_key2 key2 previous_chroma_key_0 previous_chroma_key_1 previous_chroma_key_2 previous_chroma_key_3 register & 1 key3 invert_rop select_rop alpha_rop key_pass_rop= previous_key key0 inv rop sel rop alp rop key rop invertrop selectrop alphablend keypass previous_chroma_key_3:0 for next mixer stage colorkeymaskp & register colorkeymask 1 key rop alphapass alpha_pass_rop color depth new_pixel_ key2 new_pixel_ key1 2bpp p[1] p[0] 8bpp 0 0 15bpp p[15] 0 16bpp 0 0 24bpp 0 0 32bpp p[31:24] && pixel keyand[31:24] 0 note: the generation of the new_pixel_key happens in the pixel formatter block, not in the mixer. newpixelkey= previous_key 0000 00 pass zeros to the next mixer 01 pass current color key to next mixer 10 pass previous color key to next mixer 00 reserved passcolorkey0 passcolorkey1 passcolorkey2 passcolorkey3 passcolorkey0-3 register settings
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-19 2.6.2 alpha blending blending allows video and graphics to be combined with varying levels of transparency. blending is possible only when both current and previous layer pixels are valid. either 16 or 256 levels of blend from one layer to another and vice versa are available. the blend value may come from a layers alpha register or from the upper 4 or 8 bits of an incoming pixel or is a multiplication of both. the blending is done according to the following equation: pixel_result = alpha x pixel_current + (1-alpha) x pixel_previous pre-multiplied pixel formats are supported. the premult bit is set, which means the incoming pixel stream is already pre-multiplied with the per-pixel alpha value. the resulting alpha blend equation is as follows: pixel_result = pixel_current + (1-alpha) x pixel_previous an additional per-component pre-multiply with a constant can be achieved by proper programming of the color space matrix. fading of alpha values is controlled by the alpha_mix bit. if it is set, the pixel alpha gets multiplied by the ?ed alpha value/256. remark: alpha=255 has the effect, in hardware, of making alpha equal to 1 in the above equations. 2.7 output pipeline structure the input to the output pipeline comes from the mixers. the output pipeline houses the formatter (frmt) that produces the ?al output stream in the required output format. figure 6: mixer block diagram?ixel processing previous pixel new pixel alpha invert_rop select_rop alpha_rop new mixed pixe l previous alpha alpha_reg current pixel extracted alpha previous alpha for next mixer stage alpha alpha_use_reg pixel formatter block alpha_pass_rop valid pixel? premult blend
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-20 besides two instances of the formatter, the output-interface unit also contains two instances of a chroma-downsampling unit (cdns), one instance of a gamma- correction and noise-shaping unit (gnsh) and several input-output muxes; the gamma-lookup-table allows possible gamma-correction on the ?al composited image stream, whereas the noise shaper logic reduces (dithers) the number of bits per pixel (in the gamma-corrected image) via error propagation. the insertion of vbi data into the d1 or d1-like output streams is also supported. in order to support 4:2:2 output formats, two chroma-down-sample ?ters (cdns) are included at the beginning of the input-data chain. the input multiplexer (imux) is used to appropriately select the input stream depending on the partitioned layer boundary. the interleaving unit (intl) is to be programmed in a pass-through mode. 2.7.1 supported output formats the output formatter supports the following output formats: 30-, 24- or 18-bit parallel yuv or rgb + external h- and v-sync and composite blank 10- or 8-bit d1 or d1-like 4:2:2 yuv 10- or 8-bit d1-like 4:4:4 yuv/rgb 20- or 16-bit double-interface semi-planar 4:2:2 d1 mode with 10- or 8-bit y and 10- or 8-bit u/v multiplexed data remark: the pnx15xx series digital video interface has assigned up to 30 data pins to the video output interface. refer to chapter 3 system on chip resources for the different pin assignment. 2.7.2 layer selection in the mixers, the ?al image (to be displayed) is composed (composited) from the images obtained from the various layers. 2.7.3 chrominance downsampling (cdns) chroma down-sampling is necessary for creating a yuv 4:2:2 output signal. it uses a (1,2,1)/4 low-pass ?ter to create co-sited u&v samples (because itu-r.601 speci?s only co-sited sub-sampling). every second u&v output sample is discarded, but then the other sample is repeated. consequently, the output stream is still 4:4:4 and the repeated samples have to be discarded later. 2.7.4 gamma correction and noise shaping (gnsh& onsh) the gamma-lookup-table allows possible gamma-correction on the ?al composited image stream, whereas the noise shaper logic reduces (dithers) the number of bits per pixel (in the gamma-corrected image) via error propagation. in the gnsh unit, the qvcp-internal data format is converted into the desired output format. the overshoots and undershoots which are generated by the qvcp layer units are also removed if noise shaping is off and the desired output is not the 9+1 mode; the data will be left-shifted by one bit and the msb bit will be lost.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-21 the main purpose of gamma correction is to adapt the gamma prescribed by the transmission standard to a particular display device. gamma may also be adapted to ambient light conditions (a lower gamma for a brighter environment). gamma correction should be done on rgb signals going to the display, but never on a yuv signal. the gamma correction in qvcp is based on linear interpolation.the input signal is divided into 64 segments of 16 values each. for each component, there are 2 independent look-up tables, one for the base and the other for the slope. for a strong correction, there is an optional squarer after the linear interpolator, which is recommended to be switched on when the gamma value is larger than about 1.4. the output of the gamma corrector is a 14b unsigned value. qvcp supports four output data formats: 6 bits, 8 bits, 9+1 bits, and 10 bits. they are generated by the dither unit. the dither unit uses an error-propagation algorithm, which minimize the average error caused by losing bits. 2.7.5 output interface modes the supported output interface modes are described below. note that chapter 3 system on chip resources presents how the qvcp module pins are mapped to the pnx15xx series pins. 30-, 24- or 18-bit parallel mode all video data pins are used to transport the digital video data stream without any component multiplexing. the output data format can be either yuv or rgb and 10-, 8-, or 6-bit (as determined by the noise shaping) per color component. 30-bit mode: qvcp_data[29:20]: y[9:0] or r[9:0] qvcp_data[19:10]: u[9:0] or g[9:0] qvcp_data[9:0]: v[9:0] or b[9:0] 24-bit mode: qvcp_data[29:22]: y[7:0] or r[7:0] qvcp_data[19:12]: u[7:0] or g[7:0] qvcp_data[9:2]: v[7:0] or b[7:0] 18-bit mode: qvcp_data[29:24]: y[5:0] or r[5:0] qvcp_data[19:14]: u[5:0] or g[5:0] qvcp_data[9:4]: v[5:0] or b[5:0] d1 mode 10-bit mode:
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-22 qvcp_data[9:0]: image stream with multiplexed components 8-bit mode: qvcp_data[9:2]: image stream with multiplexed components 6-bit mode: qvcp_data[9:4]: image stream with multiplexed components double d1 mode in this mode, twenty video data pins are used out of the 30. these twenty pins are used to stream out one video data stream. qvcp outputs yuv 4:2:2 by splitting y and uv into two separate streams, y uses 10 pins and the interleaved uv uses the other 10 pins. the data stream can be generated by splitting up the qvcp into two sets of layers. 10-bit mode: qvcp_data_out[19:10]: uv component of image stream qvcp_data_out[9:0]: y component of image stream 8-bit mode: qvcp_data_out[19:12]: uv component of image stream qvcp_data_out[9:2]: y component of image stream 6-bit mode: qvcp_data_out[19:14]: uv component of image stream qvcp_data_out[9:4]: y component of image stream 2.7.6 auxiliary pins qvcp has two auxiliary (aux) output pins, each of which can be independently programmed for: 1. composite blanking, where the value on the pin is asserted high (1) if either vblanking is true or hblanking is true or both are true. the complement of the value on the pin can, therefore, be used as the indicator of valid/active pixels. 2. odd/even indication, where the ?ld polarity is indicated in the interlaced mode. the value on the pin is 0 in progressive mode. 3. video/graphics indication, where the color keyn (n = 1, 2, 3, 4) of the mixer 2 is used. the corresponding color key can serve as video/graphics indicator. the two auxiliary are referenced as qvcp_aux (qvcp auxiliary 1) and vdo_aux (qvcp auxiliary 2) in chapter 3 system on chip resources .
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-23 3. programming and resource assignment 3.1 mmio and task based programming in order for the qvcp to function properly its various block have to be con?ured. each functional unit contains a set of programming registers. a more detailed description of the various registers can be found in the register description section of this document. the registers are divided in layer speci? registers and global registers. layer speci? registers are used to set up the layer related functions such as layer position, size, pixel format and various conversion functions. the global register space accommodates functions such as screen timing and output format related functions. another important part of the global register space are the resource assignment registers which allow to assign the pool resources to speci? layers. there are two ways to access the qvcp registers: 1. the ?st and primary way to get read/write access to the registers is via the mmio bus, which maps the registers into the overall pnx15xx series address space. 2. the second way to get write-only access to the registers is via data structures fetched through the vbi dma access port (used to fetch vbi data which get inserted into the output data stream). differentiation between vbi and programming data is accomplished via a different header. the data structure to be used contains a header consisting of a pointer to the next packet in memory. a null pointer indicates the last packet in a linked list. the header also contains a ?ld id ?ld which allows ?ld synchronized insertion of vbi or re- programming packets. packet insertion can cause an interrupt if the appropriate header ?g is set. a detailed view of the packet format can be found in figure 7 . each data packet consists of an 8-byte descriptor followed by data (see t ab le 5 .) table 5: data packet descriptor bit description 12:0 data byte count 13 unused 14 1=wait for proper vertical ?ld 0=send data on current ?ld without considering the ?ld id (for a series of packets to be inserted in the same ?ld, this bit should only be set for the ?st packet and not for subsequent ones. if this bit is set for all packets, they will be inserted with one ?ld delay each). 15 1=generate interrupt when this packet is transmitted 0=don? generate packet interrupt 27:16 screen line in which to insert the data packet 0=?st line after rising edge of vsync 0xfff=line compare disabled. the packet is inserted without consideration of the line counter. 30:28 field id for this packet to be sent on
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-24 3.2 setup order for the qvcp the following order is recommended for setting up the qvcp for a particular display scenario: the screen timing generator setup should be performed ?st since this is usually ?ed for the target display. once the screen timing is set up the screen timing generator should still stay disabled until all other settings are complete. in a second step the resource assignment for a particular display scenario should be set up. this involves two sub-steps: each functional unit, whether it is located inside a layer or in the resource pool, should be assigned to an aperture slot in the overall qvcp aperture. 31 data type 0=vbi data 1=register reprogram data for internal qvcp registers 59:32 next packet address 63:60 unused 61:... data if bit 31=0, the data block consists of byte vbi data if bit 31=1, each qword in the data portion is: 15:0 qvcp register address 31:16 unused 63:32 register data figure 7: vbi/programming data packet formats table 5: data packet descriptor ?ontinued bit description data byte count [12:0] v s p i 0 15 packet insertion line 16 31 field id 0 47 32 48 63 64 79 vbi-data byte 0 next packet address [59:32] lsb msb vbi-data byte 1 vbi-data byte 3 vbi-data byte 2 vbi-data byte n vbi-data byte n-1 ... data byte count [12:0] v s p i 0 15 packet insertion line 16 31 field id 1 47 32 48 63 64 79 qvcp register address 0 next packet address [59:32] lsb msb ... qvcp data 0 [31:0] lsb msb qvcp register address 1 ... qvcp data 1 [31:0] msb ... lsb qvcp register address n ... qvcp data n [31:0] msb lsb ... vbi-packet format programming data-packet format
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-25 once the aperture assignment has been determined, a matching resource assignment to the data path has to be performed. this assures that the data ?w through the qvcp is switched through the proper resources assigned to a speci? layer and a speci?-layer aperture. for details and an example about resource and aperture allocation see section 3.3 on page 11- 30 . after completing the pool resource allocation and assigning each functional unit a spot in the qvcp aperture map, the layer-speci? functions can be con?ured. if a pool resource has been assigned to a layer, its programming registers will occupy a spot in this layers aperture map. for a layer without pool resource usage, the particular spot in the aperture map will stay empty making sure that there is symmetry in the programming register location for all the layers. if writes are performed to an unoccupied spot they will be discarded. reads will return zero. once all layer speci? functions are set up, the output interface needs to be programmed in order to correctly interface with the display controller chip. after performing all these tasks the screen timing generator may be enabled. once running, the layers needed for the speci? display scenario can be enabled. this concludes the qvcp setup. once the qvcp is set up for a certain scenario and images are displayed, a number of operations can be recon?ured on the ?. among those functions are layer size and position, alpha blending and mixing functions as well as color key and various other features. 3.2.1 shadow registers whenever any picture setting needs to be changed, it is always a good idea to make it a seamless transition i.e., no noticeable artifacts should be observed by the general audience. for most use cases, the goal is to change settings in between ?lds/frames or during non-active video lines (e.g., vbi). the qvcp provides two mechanisms (programmable/selectable via a register bit) for register shadowing, whereby certain registers are shadowed to prevent screen artifacts during the recon?uration operations. one method allows all new setting changes to really take effect at any line location assigned by user. by using a duplicated set of the acting registers ?the shadow registers as they are commonly called ?any register changes will ?st get buffered, will wait for the correct time (i.e., the programmed line is the current line being processed), and then be passed to acting registers. the contents of the shadow registers are transferred to the corresponding active registers at the line location indicated by 0x10e1f0[11:0]. the user has r/w access only to the shadow registers, but not the active registers. besides a trigger from the line location indicated by the register at 0x10e1f0[11:0], the second method comprises shadowing on a positive edge of the layer-enable signal (i.e., when a disabled layer is enabled). the ?ositive edge?of layer enable implies ?hen the layer_enable register changes from 0->1? however, this positive edge triggers only the shadow registers within that speci? layer, all other layers shadow registers are not affected. in conclusion, a shadow register transfers its content to an active register at the positive edge of layer-enable, or
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-26 when the output line number is equal to the line number speci?d in the register at 0x10e1f0[11:0] an unwanted situation can arise when shadowing starts (as a result of the trigger) before the user has ?ished programming a complete sequence of register changes. to prevent this from happening, the complete register reprogramming must be followed by a ?inish?which should really trigger the shadowing. the ?inish?is activated via rewriting a value of ? to the layern_enable, which originally has value ?? this is sometimes called rehitting the layern_enable bit. by making use of this mechanism, any ?nfinished programming will only be ready for shadowing when the layern_enable is rehit. figure 13 below depicts the intended programming procedure for qvcp. remark: once the shadowing is complete, the layer upload bit is set again.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-27 figure 8 and figure 9 illustrate the shadowing procedure. figure 8: shadow mechanism v-blank h-blank viewable area setting 1 setting 2 program new settings to shadow registers at this time shadow registers passed to acting registers at reload_line[11:0] setting2 take effect layern_enable layern_enable changes from 0->1 shadow registers passed to acting registers setting 2 dma start fetch data at this time (line number 10exc8[11:0]) re-hit layern_enable right after finish the shadow programming (better before reload_line) dma start fetch data at line number 10exc8[11:0]) please consider memory read latency, at least one line before layer start. setting 3 dma dma program new settings to shadow registers any time after shadow passing re-hit layern_enable right after finish the shadow programming acting registers shadow registers viewable area video blank area video viewable area setting 1 setting 1 setting 2
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-28 t ab le 6 lists all shadowed registers (where lapt stands for layer aperture): figure 9: shadowing of registers dma pfu ckey/udth cups lint vcbm lcu fcu hsru hist x2 lshr x1 cftr x2 dcti x2 clut x2 out_if mixer stg_timing/vbi pr_dma x2 pool resource element, register not shadowed regular function unit, registers not shadowed pool resource element, register shadowed regular function unit, register shadowed table 6: shadow registers register used by dummy pixel count (0x10e[lapt]14) pixel formatter layer size (0x10e[lapt]34) pixel formatter pixel key and register (0x10e[lapt]4c) pixel formatter output and alpha manipulation (0x10e[lapt]b8) pixel formatter formats (0x10e[lapt]bc) pixel formatter variable format register (0x10e[lapt]c4) pixel formatter layer source address a (0x10e[lapt]00) dma layer pitch a (0x10e[lapt]04) dma layer source width (0x10e[lapt]08) dma layer source address b (0x10e[lapt]0c) dma layer pitch b (0x10e[lapt]10) dma dummy pixel count (0x10e[lapt]14) pixel formatter layer start (0x10e[lapt]30) layer control layer size (0x10e[lapt]34) layer control layer pixel processing (0x10e[lapt]3c) (except bits 0 and 1) pixel formatter intr (0x10e[lapt]a8) linear interpolator hsru phase (0x10e[lapt]ac) hsru hsru delta phase (0x10e[lapt]b0) hsru layer size (?al) (0x10e[lapt]b4) layer control / scalers
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-29 3.2.2 fast access registers the architecture of the qvcp mmio access results in module dependent latencies for the various con?uration registers. for most of the registers this does not present a problem since their content is usually rather static or only updated once per ?ld/ frame. some registers, however require access with relatively low latency. t ab le 7 lists the qvcp con?uration registers which can be accessed with low latency. output and alpha manipulation (0x10e[lapt]b8) pixel formatter formats (0x10e[lapt]bc) pixel formatter variable format register (0x10e[lapt]c4) pixel formatter start fetch (0x10e[lapt]c8) pixel formatter lshr_par_0 (0x10e[lapt]e8) lshr lshr_par_1 (0x10e[lapt]ec) lshr lshr_par_2 (0x10e[lapt]f0) lshr lshr_par_3 (0x10e[lapt]f4) lshr lshr_e_max (0x10e[lapt]f8) lshr lshr_e_sum (0x10e[lapt]fc) lshr lut-hist (0x10e[lapt]124) hist lut-hist (0x10e[lapt]128) hist lut-hist (0x10e[lapt]12c) hist lut-hist (0x10e[lapt]130) hist lut-hist (0x10e[lapt]134) hist lut-hist (0x10e[lapt]138) hist lut-hist (0x10e[lapt]13c) hist lut-hist (0x10e[lapt]140) hist layer histogram control(0x10e[lapt]144) (enable bit only) hist layer cftr blue (0x10e[lapt]48) cftr layer cftr green (0x10e[lapt]4c) cftr layer dcti control(0x10e[lapt]50) (enable bit only) dcti layer dcti control(0x10e[lapt]50) (enable bit only) dcti table 6: shadow registers ?ontinued register used by table 7: fast access registers register field_info (0x10 e1f8) xy_position (0x10 e1fc) interrupt status (0x10 efe0) interrupt enable (0x10 efe4) interrupt clear (0x10 efe8)
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-30 3.3 programming of layer and pool resources this section describes in detail the resource pool concept and the aperture assignment for pool and non-pool resources. a resource in general is a functional unit which performs a certain independent task in the video display chain of the qvcp. 3.3.1 resource assignment and selection if no pool resources are used, the data ?w for a single image surface through the qvcp is strictly horizontal i.e., the pixel stream ?ws through the layer and does not leave it. the pool resources are assigned by default to one of the layers. however the pool resources are bypassed by default, which results in all layers becoming identical in their function. to assign a pool resource to a different layer it requires the following: ensure that the resource shows up in the assigned layer aperture. ensure that the pixel data stream of the particular layer is directed through the selected resource. 3.3.2 aperture assignment each functional unit (resource) used in a qvcp layer has a unique identi?r. it is used to control the assignment of this resource to a speci? qvcp layer aperture location. t ab le 8 lists the resource id assignment for the functional units currently present in the qvcp. a 32-bit identi?r is used for the resource id which allows for the addition of functional units in future derivatives. interrupt set (0x10 efec) powerdown (0x10 eff4) module_id (0x10 effc) table 7: fast access registers ?ontinued register table 8: resource id assignment id functional unit 1 pfu (pixel formatter unit) 2 ckey (color key and undither unit) 3 cups (color upsampling unit) 4 lint (linear interpolator) 5 vcbm (video contrast brightness matrix) 7 lcu (layer control unit) 8 dma (control unit) 9 clut (color look up table unit) 10 hsru (horizontal sample rate converter) 11 lshr (luminance sharpening unit) 12 hist (histogram modi?ation unit)
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-31 the location of a layer in the overall qvcp address map is shown in t ab le 9 . each functional unit which belongs to a layer occupies a ?ed spot within the layer address range of 0x200h bytes. however the layer assignment of this functional unit is programmable. it should usually follow the pixel data ?w for a speci? image surface through the functional units involved. two 32-bit registers, resource_id and fu_assignment, are used to assign all resources to a speci? layer address space. one is used to identify the resource to be assigned. the other register is split up into 4-bit chunks which contain the speci? assignment for the resource identi?d in the ?st register. this allows for up to 8 resources of the same kind per functional unit. in this speci? qvcp implementation only a maximum of two of the same kind of each resource is needed for non-pool resources and only one location is needed for the pooled resource. the remaining slots are reserved for future implementations. the two registers act as access points to an internal table which keeps the programmed values. all resources are programmed through the same two registers. the id register has to be written ?st. t ab le 10 outlines the association of a given rn {n=0..5} value to an address space. the value of rn {n=0..5} is equivalent to the mmio offset bits [12:9]. 13 cftr (color features) 14 dcti (dynamic color transient improvement) 15 plan (semi planar channel) table 9: register space allocation address range function 0x0h - 0x1ffh global qvcp register space 0x200h - 0x3ffh layer 1 register space 0x400h - 0x5ffh layer 2 register space figure 10: resource layer and id table 10: rn association rn address space 0 reserved for global qvcp addresses 1 0x200h - 0x3ffh (layer 1) 2 0x400h - 0x5ffh (layer 2) table 8: resource id assignment ?ontinued id functional unit resource id r1 r2 res. res. res. res. res. res. 0 4 8 12 16 20 24 28 resource id register (rid) resource-layer assignment register
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-32 the usage of address bit 12 would indicate a 8 kb aperture space for the qvcp. this is however not the case, in the current implementation only bits 11:9 are used because the qvcp occupies only a 4 kb address space. the 12?h bit is reserved for future extensions and alignment purposes. 3.3.3 data flow selection pool resources are functional units which do not have a xed assignment to a speci? layer. depending on the use case a resource is assigned to a speci? layer. two 32-bit registers, pool_resource_id and pool_resource_layer_assignment, are used to assign a speci? resource to a layer. one is used to identify the resource to be assigned. the other register is split up into 4-bit chunks which contain the speci? assignment for the resource identi?d in the ?st register. this allows for up to 8 resources of the same kind per functional unit. in this speci? qvcp implementation, only two of the same kinds of pool resources are needed. the remaining 6 slots are reserved for future implementation. these two registers act in the same way as described earlier for the aperture assignment. they are used to perform the assignment for all resources, which is again stored in an internal table in which the two registers are the access point. the id register has to be programmed ?st. the resource layer assignment for the 2-layer, 1-pool resource scenario is shown in figure 12 . figure 11: resource layer and id table 11: resource-layer assignment for pool resource pr1 assignment 4?000 resource is assigned to layer 1. 4?001 resource is assigned to layer 2. figure 12: 2-layer 1 resource elements scenario pool resource id pr1 res. res. res. res. res. res. res. 0 4 8 12 16 20 24 28 pool resource id register (prid) pool resource assignment register pr1 in1 in2 out1 out2 pool mux
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-33 note that due to resource assignment, the layers where the data stream leaves a pool element are potentially at a different layer than where it entered, hence the horizontal data ?w structure no longer exists. if for instance in figure 12 , layer 2 is con?ured to use resource 1, the data that will enter at in2 will leave the pool element at out1 and the data stream entering at in1 will leave at out2. the consequence is that all subsequent functional units will see layers 1 and 2 swapped. it should be obvious that the subsequent units will have to be recon?ured to show up in a different layer aperture. if further down in the display pipe another swap is needed, the subsequent blocks again have to be aperture reassigned. if a con?uration requires the pixel stream for a particular image surface to leave in the same layer as it entered, there is a cross- bar implementation at the far end of the layer. this allows arbitrary assignment of an input layer to a different output layer. this cross-bar can also be used to implement a ??reordering of image surfaces. as a general guideline for the aperture map assignment, one should assign all functional units through which a pixel data stream originating from pixel formatter n ?ws, to the aperture space n regardless of whether the data ?w is horizontal or zig- zag due to pool resource reassignments.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-34 3.3.4 pool resource assignment example figure 13 illustrates a programming example for pool and aperture reassignments. figure 13: pool and aperture reassignments pfu dma clut ckey cups hsru lint lshr vcbm lcu fla pfu dma ckey cups lint vcbm lcu fla rid:8 fu:21 pid:n.a. pr1:n.a. rid:1 fu:21 pid:n.a. pr1:n.a. rid:9 fu:x2 pid:9 pr1:1 rid:2 fu:12 pid:n.a. pr1:n.a. rid:3 fu:12 pid:n.a. pr1:n.a. rid:10 fu:x1 pid:10 pr1:1 rid:4 fu:21 pid:n.a. pr1:n.a. rid:11 fu:x2 pid:11 pr1:0 rid:5 fu:12 pid:n.a. pr1:n.a. fla1:2 fla2:1
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-35 3.4 programming the stg because the stg coordinate system begins at (0,0), its necessary to program certain registers to one less than the desired value. for example, a scan line has 800 pixels total. the horizontal total should be set to 799 because 0?99 is a total of 800. the same applies to programming the vertical total. in the vertical domain, there are three main timing intervals to set: vertical active time, vertical blank time, and vertical sync time. the position of the vertical sync de?es the vertical front and back porches. note that the vertical sync interval (and therefore vertical blanking) must be a minimum of one line in duration. the stg has no speci? requirement for horizontal blank and sync. the location, duration and even existence of horizontal blank and sync times is entirely display surface dependent. if the display surface does not require horizontal blanking, its not necessary to program it into the stg. non-blanked area occurs when the currently active line is not within the vertical blanking interval or in the column of the horizontal blanking interval. display layers can be programmed to reside on any portion of the screen. any non-blanked screen position that does not have an active display layer pixel assigned to it will result in the background color or the previous layer pixel being displayed. figure 14: video frame screen timing horizontal total horizontal blank end horizontal sync end horizontal sync start horizontal blank start vertical total vertical blank end vertical sync end vertical sync start vertical blank start active display area
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-36 the qvcp provides clipping support at the edge of the de?ed h- and v-total. if a layer is positioned in a way that some part of it would exceed the overall screen dimensions, no wrapping occurs but the pixel layering in this area is marked as invalid, hence they are not being displayed. the qvcp also supports negative screen positions i.e., top and left side clipping of layers. for negative x and y layer start positions, the following equations must be used: if startx < 0 then startx = xtotal + 1 - abs(startx) set startx sign bit starty = ydisplay - 1 else startx = startx starty = starty if starty < 0 then starty = ytotal + 1 - abs(starty) set starty sign bit else starty = starty in addition to the standard progressive qvcp display mode, another mode called ?nterlaced?can be switched on by setting the interlaced control bit. in this mode the vtotal register no longer speci?s the height of a frame but the height of a ?ld. the ?ld height alternates by one line depending on whether an odd or even ?ld needs to be processed by the qvcp. four registers are provided for this mode to specify the actual location of the vsync signal within a line in odd and even ?lds. 3.4.1 changing timing all register settings to the timing generator take effect immediately and are not clock re- synchronized. (the start/stop bit is the exception. it takes effect immediately and is clock re-synchronized.) the only safe way to change screen timing is as follows: 1. turn off the timing generator. 2. program all registers needed in the new display mode. 3. turn the timing generator back on. in the process, the entire display pipeline is reset. all display layers are reset, and the screen timing starts at the vertical total, which guarantees a complete vertical blank period and vertical sync signal at the start of any mode change. 3.5 programming qvcp for different output formats t ab le 12 shows the programmer how to obtain the desired output formats. the programming bits reside in the ?ontrol?register (offset 0x03c).
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-37 4. application notes 4.1 special features 4.1.1 signature analysis signature analysis is a feature where qvcp calculates a 16-bit signature on the upper 8 bits of each mixer output separately and sends it to a register which can be read easily once ?ig_done?of the signature3 register (offset 0x10e058) is set. qvcp follows a speci? crc algorithm to calculate the signature. the signature analysis can be done independently on each layer output. also, the signatures of data (alpha, upper, middle, lower path) and control (misc path, which consists of vsync, hsync, blank etc.) can be read separately. see the registers with offsets 0x10e050, 0x10e054 and 0x10e058 for more details. 4.2 programming help the tables below attempt to provide some help in choosing the programming parameters for some of the video enhancement modules. it is to be noted, however, that the parameter settings shown below are just example settings that worked well on a particular experimental picture. one particular setting will not optimize the enhancement effects for different images (even when they are part of a sequence). for the real application, the parameters need to be adjusted, by the control software, according to the measurement results (obtained from assorted measurement units in other video modules of the parent chip). table 12: programming values for supported pnx15xx series output formats format out_mode d1_mode interleave oversample clk_ratio ten-bit output format parallel 2 1 x x 1:1 1/0 up: yyyyyy md: uuuuuu lo: vvvvvv d1 interface (422) 01011:21/0 lo: uyvyuy...stream d1 interface (444) 00011:31/0 lo: yuvyuv...stream double d1 11011:11/0 md: uvuvuvuvuvu lo: yyyyyyyyyyyy
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-38 4.3 lint parameters the phase of the ?st output pixel is programmed using pcoeff (reg 0x10,e2a8[21:16]). the upscaling ratio is programmed in dpcoeff (reg 0x10,e2a8[11:0]). t ab le 13 shows the min-max values of the lint programming parameters. if scaling ratio == 1 dpcoeff = 0 // the decimal bits for 1.0000_0000_0000 else dpcoeff = (1000 * h) / scaling ratio 4.4 hsru parameters the phase of the ?st output pixel is programmed via hsru_phase (reg 0x10 e2ac[5:0]). hsru_d_phase (reg 0x10e2ac[27:16]) is the ?st-order phase difference of the ?st output pixel, while hsru_dd_phase (reg 0x10 e2b0[11:0]) and hsru_ddd_phase (reg 0x10 e2b0[25:16]) are the second and the third-order phase differences, respectively, of the ?st output pixel. t ab le 14 shows the min-max values of the programmable hsru parameters. note that the decimal points are actually aligned for the different values and ?: stands of the sign extension that is automatically performed by hardware (only the lower non-s values need to be programmed). for bypassing the hsru, all the control parameters have to be set to 0. table 13: lint programming register bits value type minimum value maximum value pcoeff (0x10 e2a8[21:16]) unsigned 0.0000_00 0.1111_11 dpcoeff (0x10 e2a8[11:0]) unsigned 0.0000_0000_0001 1.0000_0000_0000 table 14: hsru programming register bits value type minimum value maximum value hsru_phase (0x10 e2ac[5:0]) unsigned 0.0000_00 0.1111_11 hsru_d_phase ( 0x10e2ac[27:16]) unsigned 0.0000_0000_0001 1.0000_0000_0000 hsru_dd_phase ( 0x10 e2b0[11:0]) signed s.ssss_ss10_0000_0 000_00 s.ssss_ss01_1111_1 111_11 hsru_ddd_phase ( 0x10 e2b0[25:16]) signed s.ssss_ssss_ssss_ss 10_0000_0000 s.ssss_ssss_ssss_ss 01_1111_1111
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-39 4.5 lshr parameters table 15: lshr programming parameters register bits reset value setting gentle strong lshr_par_0 offset: 0x10 e2e8 31 - enable lshr 0 1 1 30:24 - hdp_coring_thr 0 8 4 23:21 - hdp_neg_gain 0 4 4 20:18 - hdp_delta 0 2 2 17:14 - hdp_hpf_gain 0 4 7 13:10 - hdp_bpf_gain 0 4 4 9:6 - hdp_epf_gain 0 4 8 5:3 - kappa 0 0 0 2 - enable_lti 0 1 1 1 - enable_cds 0 1 1 0 - enable_hdp 0 1 1 lshr_par_1 offset: 0x10 e2f0 31 - wide_format 0 0 0 30:19 - unused 0 0 0 18:12 - lti_coring_thr 0 16 8 11:8 - lti_hpf_gain 0 0 0 7:4 - lti_hpf_gain 0 0 2 3:0 - lti_hpf_gain 0 4 6 lshr_par_2 offset: 0x10 e2f4 31:0 - energy_sel 0 2 2 29:25 - unused 0 24:18 - lti_max_gain 0 64 127 17:14 - lti_steep_gain 0 12 12 13:6 - lti_base_gain 0 -16 -16 5:3 - lti_steep_taps 0 3 3 2:0 - lti_minmax_taps 0 2 2
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-40 4.6 dcti parameters 4.7 cftr parameters 4.8 under?w behavior this section briefs on the under?w handling in qvcp. table 16: dcti programming parameters register bits reset value setting gentle strong layer dcti control offset: 0x10 e350 31:16 - unused 15 - superhill 1 1 1 14:11 - threshold 4 8 4 10 - separate 0 0 0 9 - protection 1 1 1 8:6 - limit 7 2 7 5:2 - gain 8 2 8 1 - ddx sel 1 1 1 0 - enable 0 1 0 table 17: cftr programming parameters register bits reset value setting gentle strong layer cftr blue/skin tone offset: 0x10 e348 31:25: - unused 24 - blueycomp 1 0 1 23:20 - bluegain 10 10 15 19:17 - bluesize 4 2 0 16: blue_enable 0 1 1 15:9 - unused 8:6 - skingain 2 2 3 5:3 - skintone 2 2 7 2:1 - skinsize 1 1 3 0 - skin_enable 0 1 1 layer cftr green offset: 0x10 e34c 31:15 - unused 14:11 - greenmax 9 9 15 10:8 - greensat 4 4 7 7:4 - greengain 7 7 15 3:1 - greensize 0 2 0 0 - green_enable 0 1 1
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-41 4.8.1 layer under?w any time the layer position has reached but the small 16-pixel fifo at the end of every layer pipe has run out of available pixels, under?w occurs. 4.8.2 under?w symptom only portion of a picture is displayed or occasional blinking of picture happens under?w interrupt bit is set. 4.8.3 under?w recovery should an under?w occur, the layer would fetch and dump remaining data for the current ?ld/frame. the next ?ld/frame would be fetched and displayed as normal. 4.8.4 under?w trouble-shooting check if the dma source width settings (0x10,ex08) matches the initial layer width (0x10,ex34) check if the initial layer width (0x10,ex34) matches the ?al layer width (0x10,exb4) for the non-scaled layer. check if the ?al layer width (0x10,exb4) is within acceptable cropping range for lint or hsru scaling. check whether the dma start fetch (0x10,exc8) is at line number too close to the display position. note that about 64 pixels is qvcps input-to-output latency. so, depending on the system-memory latency, the dma fetch should start as early as possible, in order to make up for the request-to-data latency. check if the system memory arbiter is giving high priority to qvcp. check if qvcp demands exceed allocated memory bandwidth. 4.8.5 under?w handling the under?w interrupt status would stay asserted until an interrupt-status-clear is programmed.
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-42 4.9 clock calculations t ab le 18 below cites a few examples for pixel and output clock calculations for some target resolutions. table 18: interface characteristics for some target resolutions display modes interface mode sync interface speed 4:2:2 cvbs or y/c pal/ntsc/secam resolution 4:2:2 example pal: 864 pixel/line x 312.5 lines/?ld x 50hz = 13.5mhz/y samples 7.5 mhz/u samples 7.5 mhz/v samples 4:2:2 muxed components embedded sav/eav d1 style 27 mhz 4:4:4 rgb or yuv pal/ntsc/secam resolution 4:4:4 example pal: 864 pixel/line x 312.5 lines/?ld x 50hz = 13.5 mhz/ component 4:4:4 muxed components embedded sav/eav d1 style or external h/v/ blank 40.5 mhz 4:4:4 rgb or yuv 2fh (double line frequency -> double refresh rate) example pal: 864 pixel/line x 312.5 lines/?ld x 50hz x2 = 27 mhz/ component 4:4:4 muxed components embedded sav/eav d1 style or external h/v/ blank 81 mhz 4:4:4 rgb or yuv 480p (pal/ntsc resolution, progressive) example pal: 864 pixel/line x 625 lines/?ld x 50hz = 27 mhz/component 4:4:4 muxed components embedded sav/eav d1 style external h/v/ blank 81 mhz 4:4:4 rgb or yuv 1920x1080@60i example: ?920 active pixels per line (2200 total), 1080 active lines per frame (1125 total), 30 frames (60 ?lds) per second = 2200x 1125x 30 = 74.25 mhz 4:4:4 3x10 bits planar output external h/v/ blank 74.25 mhz
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-43 5. register descriptions 5.1 register summary t ab le 19 summarizes the mmio registers of qvcp. the offset are absolute offset relative to the mmio_base. only layer 1 mmio registers are displayed. layer 2 mmio registers are similar to layer 1 mmio registers but are located at offset 0x10e400 instead of 0x10e200. table 19: register module association offset symbol module 0x10 e000 total 0x10 e004 hblank 0x10 e008 vblank 0x10 e00c hsync 0x10 e010 vsync control and interrupt registers 0x10 e014 vinterrupt 0x10 e018 features 0x10 e01c default background color 0x10 e020 control 0x10 e024 final_layer_assignment 0x10 e028 intlctrl1 0x10 e02c reserved 0x10 e030 vbi src address 0x10 e034 vbi_ctrl 0x10 e038 vbi_sent_offset 0x10 e03c out_ctrl 0x10 e040 pool_resource_id 0x10 e044 pool_resource_layer_assignment 0x10 e048 resource_id 0x10 e04c fu_assignment 0x10 e050 signature1 0x10 e054 signature2 0x10 e058 signature3 0x10 e05c output pedestals1 0x10 e060 output pedestals2 0x10 e064 output gnsh lut data upper 0x10 e068 output gnsh lut data middle 0x10 e06c output gnsh lut data lower 0x10 e070 output onsh ctrl 0x10 e074 output gamma ctrl
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-44 0x10 e1f0 shadow reload 0x10 e1f8 field_ info 0x10 e1fc xy_ position layer & mixer registers 0x10 e200 layer source address a (packed/semi planar y) dma 0x10 e204 layer source pitch a (packed/semi planar y) dma 0x10 e208 layer source width (packed/semi planar y) dma 0x10 e20c layer source address b (packed/semi planar y) dma 0x10 e210 layer source pitch b (packed/semi planar y) dma 0x10 e214 dummy pixel count pfu 0x10 e218 layer source address a (semi planar uv) dma 0x10 e21c layer source address b (semi planar uv) dma 0x10 e228 layer source pitch (semi planar uv) dma 0x10 e22c layer source width (semi planar uv) dma 0x10 e230 layer start lcu 0x10 e234 layer size lcu/dma 0x10 e238 pedestal and o/p format ckey(udth) 0x10 e23c layer pixel processing dma/lcu(mix)/cups 0x10 e240 layer status/control lcu/pfu/dma 0x10 e244 lut programming lut 0x10 e248 lut addressing lut 0x10 e24c pixel key and register pfu 0x10 e250 color key1 and mask ckey 0x10 e254 color key up1 ckey 0x10 e258 color key low1 ckey 0x10 e25c color key replace1 ckey 0x10 e260 color key2 and mask ckey 0x10 e264 color key up2 ckey 0x10 e268 color key low2 ckey 0x10 e26c color key replace2 ckey 0x10 e270 color key3 and mask ckey 0x10 e274 color key up3 ckey 0x10 e278 color key low3 ckey 0x10 e27c color key replace3 ckey 0x10 e280 color key4 and mask ckey 0x10 e284 color key up4 ckey 0x10 e288 color key low4 ckey 0x10 e28c color key replace4 ckey table 19: register module association ?ontinued offset symbol module
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-45 0x10 e290 color key mask/rop lcu(mix) 0x10 e294 pixel invert/select rop lcu(mix) 0x10 e298 alpha blend/key pass lcu(mix) 0x10 e29c alpha pass lcu(mix) 0x10 e2a0 color key rops 1/2 lcu(mix) 0x10 e2a4 color key rops 3/4 lcu(mix) 0x10 e2a8 intr intr 0x10 e2ac hsru phase hsru 0x10 e2b0 hsru delta phase hsru 0x10 e2b4 layer size (?al) intr/hsru/lcu 0x10 e2b8 output and alpha manipulation pfu/lcu(mix)/ckey 0x10 e2bc formats pfu/ckey 0x10 e2c0 layer background color lcu(mix) 0x10 e2c4 variable format register pfu 0x10 e2c8 start fetch dma/pfu 0x10 e2cc brightness & contrast vcbm 0x10 e2d0 matrix coef?ients 1 vcbm 0x10 e2d4 matrix coef?ients 2 vcbm 0x10 e2d8 matrix coef?ients 3 vcbm 0x10 e2dc matrix coef?ients 4 vcbm 0x10 e2e0 matrix coef?ients 5 vcbm 0x10 e2e8 lshr_par_0 lshr 0x10 e2ec lshr_par_1 lshr 0x10 e2f0 lshr_par_2 lshr 0x10 e2f4 lshr_par_3 lshr 0x10 e2f8 lshr_e_max lshr 0x10 e2fc lshr_e_sum lshr 0x10 e300 lshr measurement window start lshr 0x10 e304 lshr measurement window end lshr 0x10 e320 layer solid color lcu(mix) 0x10 e324 layer lut-hist bins 00 to 03 hist 0x10 e328 layer lut-hist bins 04 to 07 hist 0x10 e32c layer lut-hist bins 08 to 011 hist 0x10 e330 layer lut-hist bins 12 to 15 hist 0x10 e334 layer lut-hist bins 16 to 19 hist 0x10 e338 layer lut-hist bins 20 to 23 hist 0x10 e33c layer lut-hist bins 24 to 027 hist 0x10 e340 layer lut-hist bins 28 to 31 hist table 19: register module association ?ontinued offset symbol module
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-46 5.2 register tables 0x10 e344 layer histogram control hist 0x10 e348 layer cftr blue cftr 0x10 e34c layer cftr green cftr 0x10 e350 layer dcti control dcti table 20: qvcp 1 registers bit symbol acces s value description screen timing generator registers offset 0x10 e000 total 31:28 unused - 27:16 htotal r/w 0 horizontal total sets the number of horizontal pixels for the display. total # of pixels per line = htotal+1. 15:12 unused - 11:0 vtotal r/w 0 vertical total sets the number of vertical pixels for the display. total # of lines per frame = vtotal +1. total # of lines for odd ?ld = vtotal +1. total # of lines for even ?ld = vtotal +2 offset 0x10 e004 hblank 31:28 unused - 27:16 hblanks r/w 0 horizontal blank start sets the pixel location where horizontal blanking starts. limitation: htotal+2 >= hblanks >= 2. 15:12 unused - 11:0 hblnke r/w 0 horizontal blank end sets the pixel location where horizontal blanking ends. limitation: htotal >= hblnke >=0. offset 0x10 e008 vblank 31:28 unused - 27:16 vblanks r/w 0 vertical blank start sets the pixel location where vertical blanking starts. limitation: vtotal+1 >=vblanks >=1. 15:12 unused - 11:0 vblanke r/w 0 vertical blank end sets the pixel location where vertical blanking ends. limitation: vtotal >= vblanke >=0. offset 0x10 e00c hsync 31:28 unused - 27:16 hsyncs r/w 0 horizontal sync start sets the pixel location where horizontal sync starts. limitation: htotal+2 >= hsyncs >=2. 15:12 unused - 11:0 hsynce r/w 0 horizontal sync end sets the pixel location where horizontal sync ends. limitation: htotal >= hsynce >=0. offset 0x10 e010 vsync 31:28 unused - table 19: register module association ?ontinued offset symbol module
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-47 27:16 vsyncs r/w 0 vertical sync start sets pixel location where vertical sync starts. limitation: vtotal+1 >= vsyncs >=1. 15:12 unused - 11:0 vsynce r/w 0 vertical sync end sets pixel location where vertical sync ends. limitation: vtotal >= vsynce >=0. control and interrupt registers offset 0x10 e014 vinterrupt 31:28 unused - 27:16 vlinta r/w 0 vertical line interrupt a sets a vertical line number where an interrupt will be generated when the scan line matches this value. the interrupt is monitored by the event monitor (evm). limitation: vtotal >= vlinta >=0. 15:12 unused - 11:0 vlintb r/w 0 vertical line interrupt b sets a vertical line number where an interrupt will be generated when the scan line matches this value. the interrupt is monitored by the event monitor (evm). limitation: vtotal >= vlintb >=0. offset 0x10 e018 features 31:30 noout r 0x1 number of output channels 29:27 unused - 26:24 nognsh r 0x1 number of gnshs 23:21 noplan r 0x1 number of plans (semi planar channels) 20:18 nolshr r 0x1 number of lshrs 17:15 nohsru r 0x1 number of hsrus 14:12 nohist r 0x1 number of hists 11:9 nocti r 0x1 number of ctis 8:6 nocftr r 0x1 number of cftrs 5:3 nocluts r 0x1 number of cluts 2:0 nolayers r 0x2 number of layers offset 0x10 e01c default background color 31:24 unused - 23:16 upper r/w 0 background color of the upper channel (r/y) (two's complement) 15:8 middle r/w 0 background color of the middle channel (g/u) (two's complement) 7:0 lower r/w 0 background color of the lower channel (b/v) (two's complement) table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-48 offset 0x10 e020 control 31:30 unused - 29 interlaced r/w 0 interlaced mode bit 0 = non-interlaced mode; vtotal=frame height. 1 = interlaced mode field height = vtotal for odd ?lds. field height = vtotal+1 for even ?lds. o_e ?g = 0 for odd (bottom) ?lds o_e ?g =1 for even (top) ?lds 28 blankpol r/w 0 blank polarity 0 = positive blank 1 = negative blank 27 unused - 26 hsyncpol r/w 0 hsync polarity 0 = positive going 1 = negative going 25 unused - 24 vsyncpol r/w 0 vsync polarity 0 = positive going 1 = negative going 23:21 unused - 20 blankctl r/w 0 blank control allows either normal blanking or forces blanking to occur immediately. 0 = blank output is equivalent to blankpol setting 1 = normal blank 19 unused - 18 hsyncctl r/w 0 hsync control enables or disables the horizontal sync output of the chip. 0 = hsync output is equivalent to hsyncpol setting 1 = enable 17 unused - 16 vsyncctl r/w 0 vsync control enables or disables vertical sync output of the chip. 0 = vsync output is equivalent to vsyncpol setting 1 = enable 15:12 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-49 11:8 auxctrl2 r/w 0 [9:8] = 2?00 => output acts like a composite blanking signal controlled with blankpol and blankctl [9:8] = 2?01 => pouts odd/even signal in interlaced modes, zero in progressive modes [9:8] = 2?10 => [11:10] = 2?00 => outputs colorkey1 of mixer 2 [11:10] = 2?01 => outputs colorkey2 of mixer 2 [11:10] = 2?10 => outputs colorkey3 of mixer 2 [11:10] = 2?11 => outputs colorkey4 of mixer 2 [9:8] = 2?11 => reserved 7:4 auxctrl1 r/w 0 [5:4] = 2?00 => output acts like a composite blanking signal controlled with blankpol and blankctl [5:4] = 2?01 => pouts odd/even signal in interlaced modes, zero in progressive modes [5:4] = 2?10 => [7:6] = 2?00 => outputs colorkey1 of mixer 2 [7:6] = 2?01 => outputs colorkey2 of mixer 2 [7:6] = 2?10 => outputs colorkey3 of mixer 2 [7:6] = 2?11 => outputs colorkey4 of mixer 2 [5:4] = 2?11 => reserved 3 data_oen r/w 0 output enable control for video data bus 0=data outputs enabled (normal operation) 1=data outputs disabled (tri-state) 2 trigger_pol r/w 1 external trigger, i.e. vsync, polarity for the slave mode. 1 = positive edge (default) 0 = negative edge 1 master r/w 0 stg master/slave/operation 0 = master mode 1 = slave mode 0 tgrst r/w 0 timing generator reset 0 = disable 1 = enable disable will reset all layer_enable bits (global qvcp reset). offset 0x10 e024 final_layer_assignment 31:8 unused - 7:4 fla2 r/w 1 layer assignment to mixer 2 3?000: input layer1 => mixer 2 3?001: input layer 2=> mixer 2 all other settings are reserved 3:0 fla1 r/w 0 layer assignment to mixer 1 3?000: input layer1 => mixer 1 3?001: input layer 2=> mixer 1 all other settings are reserved offset 0x10 e028 intlctrl1 31:28 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-50 27:16 int_start_e r/w 0 horizontal offset for vsync start even ?ld (interlaced mode only) vsync appears at int_start_e + 1. 15:12 unused - 11:0 int_start_o r/w 0 horizontal offset for vsync start odd ?ld (interlaced mode only) vsync appears at int_start_o + 1. offset 0x10 e030 vbi src address 31:28 unused - 27:0 vbi_src_addr r/w 0 vbi data source address offset 0x10 e034 vbi_ctrl 31:1 unused - 0 vbi_en r/w 0 enable vbi data fetch engine. offset 0x10 e038 vbi_sent_offset 31:12 unused - 11:0 vbi_sent_offset r/w 0 this programming value speci?s the number of lines to add to the linecnt value in the packet identi?r. offset 0x10 e03c out_ctrl 31:25 unused - 24 tc_outs1r/y r/w 1 set to unsigned format for the y/r channel of the d1 slice: 1 = invert the msb of the y/r channel for the d1 slice 0 = leave d1 slice untouched 23 tc_outs1g/u r/w 1 set to unsigned format for the u/g channel of the d1 slice: 1 = invert the msb of the u/g channel for d1 slice 0 = leave d1 slice untouched 22 tc_outs1b/v r/w 1 set to unsigned format for the v/b channel of the d1 slice: 1 = invert the msb of the v/b channel for d1 slice 0 = leave d1 slice untouched 21 dns1 r/w 0 444:422 down sample enable 1 = down sample ?ter enabled 0 = down sample ?ter bypassed 20:19 unused - 18 quali?r r/w 0 1 = slice quali?r is put out 0 = hsync is put out 17:16 outmode r/w 0 00 = output interface runs is d1 mode 01 = output interface runs in double-d1 mode 10 = output interface operates in up to 30 bit parallel mode 11 = unused 15 parallel_mode r/w 0 this bit controls the sync delay compensation. 1 = syncs are delayed (needed for 24-bit parallel output mode) 0 = no additional sync delay 14:13 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-51 12 oversample r/w 1 this bit enables the output state machine for oversampling. this bit should be 0 for interleaved output modes. if one (only supported for a single d1 stream, either 444 or 422 or 444x) the output clock should be 2x the streaming clock i.e. 422 sd mode: streaming clock 27 mhz, output clock 54 mhz results in a 2x oversampling of the data stream. 1 = oversampling enabled 0 = no oversampling 11 unused - 10 d1_mode r/w 1 1 = 4:2:2 d1 mode 0 = 4:4:4 d1 mode 9:3 unused - 2:0 mux_sel_1 r/w 0 tap off selection for ?st slice 0 = tap off after ?st mixing stage 1 = tap off after second mixing stage all other values are reserved offset 0x10 e040 pool_resource_id 31:4 unused - 3:0 pid r/w 0 pool resource id register 9 = color look up table 10 = horizontal sample rate converter 11 = luminance sharpening unit 12 = histogram modi?ation unit 13 = color features 14 = dynamic color transient improvement 15 = semi planar channels offset 0x10 e044 pool_resource_layer_assignment 31:4 unused - 3:0 pr1 r/w 0 resource 1 assignment 4?0000=layer 1 4?0001=layer 2 all other values are reserved offset 0x10 e048 resource_id 31:4 unused - 3:0 rid r/w 0 resource id register offset 0x10 e04c fu_assignment 31:20 unused - 19:16 r5 r/w 0 4?0001=layer 1 4?0010=layer 2 all other values are reserved, this register is not applicable for pool resources 15:12 r4 r/w 0 4?0001=layer 1 4?0010=layer 2 all other values are reserved, this register is not applicable for pool resources table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-52 11:8 r3 r/w 0 4?0001=layer 1 4?0010=layer 2 all other values are reserved, this register is not applicable for pool resources 7:4 r2 r/w 0 4?0001=layer 1 4?0010=layer 2 all other values are reserved 3:0 r1 r/w 0 4?0001=layer 1 4?0010=layer 2 all other values are reserved offset 0x10 e050 signature1 31:16 middle signature r 0 middle path signature 15:0 lower signature r 0 lower path signature offset 0x10 e054 signature2 31:16 alpha signature r 0 alpha path signature 15:0 upper signature r 0 upper path signature offset 0x10 e058 signature3 31:16 misc signature r 0 other signature 15:9 unused - 8 sig_done r 0 signature done 7:6 unused - 5:3 sig_select r/w 0 signature select 3?000 = layer 1 output selected for signature analysis 3?001 = layer 2 output selected for signature analysis all other values are reserved 2:1 unused - 0 sig_enable r/w 0 signature enable offset 0x10 e05c output pedestals1 31:24 unused - 29:20 upper_ped1 r/w 0 pedestal added to upper value (signed value from -512 to 511) 19:10 middle_ped1 r/w 0 pedestal added to upper value (signed value from -512 to 511) 9:0 lower_ped1 r/w 0 pedestal added to upper value (signed value from -512 to 511) offset 0x10 e064 output gnsh lut data upper 31:20 unused - 19:10 base_upper r/w 0 upper data for gamma base table 9:0 delta_upper r/w 0 upper data for gamma delta table offset 0x10 e068 output gnsh lut data middle 31:20 unused - 19:10 base_middle r/w 0 middle data for gamma base table table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-53 9:0 delta_middle r/w 0 middle data for gamma delta table offset 0x10 e06c output gnsh lut data lower 31:20 unused - 19:10 base_lower r/w 0 lower data for gamma base table 9:0 delta_lower r/w 0 lower data for gamma delta table offset 0x10 e070 output onsh ctrl 31:21 unused r/w 0 4:3 gnsh_error r/w 0 gnsh error mode 00= truncation 01= rounding 10= error propagation - not initialized except power-on 11= error propagation - initialized with hblank 2:1 gnsh_size r/w 0 gnsh output resolution 00 = 9 bits 01 = 8 bits 10 = 10 bits 11 = 6bits 0 gnsh_422 r/w 0 gnsh mode 1 = yuv 4:2:2 0 = yuv 4:4:4 / rgb offset 0x10 e074 output gamma ctrl 31 gamma_enable r/w 0 gamma correction enable bit (also disables signal range adjustment & clipping if non-(9+1) bit mode selected) 1=active 0=bypass 30 host_enable r/w 0 this enables the host read/write access to gnsh 1=host access enabled 0=host access disabled, no access possible 29:25 unused - - 24 gnsh_square r/w 0 gamma correction with squaring enable bit 1=active 0=bypass 23:22 unused - - 21:16 upper_addr r/w 0 internal address in the upper gamma delta and base tables 15:14 unused - - 13:8 middle_addr r/w 0 internal address in the middle gamma delta and base tables 7:6 unused - - 5:0 lower_addr r/w 0 internal address in the lower gamma delta and base tables offset 0x10 e1f0 shadow_reload 31 reserved r/w 0 should always set to 0 30 reload_mode r/w 0 0: reload all together at line location indicated by reload_line. 1: always reload at end pixel of the layer (old mode, do not use) table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-54 29:12 unused r 0 11:0 reload_line r/w 0 line count number where shadow reload occurs. please make sure reload line is set to a position earlier than layer start y position given in 0x10,e230. offset 0x10 e1f8 field_ info 31:3 unused - 2:0 field_id r - field_id is reset by disabling the screen timing generator field_id is incremented with each rising edge of vsync and wraps around after reaching the value 0x7 which yields a sequence of 8 ?lds which could be differentiated by using the field_id register. offset 0x10 e1fc xy_ position 31 o_e_stat r 0 odd/even ?g status (interlaced mode) 0 = first ?ld (odd/top ?ld) 1 = second ?ld (even/bottom ?ld) 30:28 unused - 27:16 stg_y_pos r - current vertical position of screen timing generator 15:12 unused - 11:0 stg_x_pos r - current horizontal position of screen timing generator layer & mixer registers the structure of each layer function block is identical. the register for a function such as source address in layer 1, has the same structure as the corresponding register in layer 2. layer one starts at offset 0x200 from the qvcp base address. layer two starts at offset 0x400 from the qvcp base address. offset 0x10 e200 layer source address a (packed/semi planar y) 31:28 unused - 27:0 layer n source address a r/w 0 layer n source data start address a in bytes. this sets starting address a for data transfers from the linear frame buffer memory to layer n. for semi planar and planar modes this address points to the y plane. note: it should be aligned on a 128-byte boundary for memory performance reasons. it has to be 8-byte aligned. offset 0x10 e204 layer source pitch a (packed/semi planar y) 31:23 unused - 22:0 layer n pitch a r/w 0 layer n source data pitch b in bytes. this sets pitch a for data transfers from the linear frame buffer memory to layer n. for semi planar and planar modes this determines the pitch for the y plane. the value has to be rounded up to the next 64-bit word. offset 0x10 e208 layer source width (packed/semi planar y) 31:23 unused - 12:0 layer n source width r/w 0 layer n source width in bytes. for semi planar and planar modes this determines the source data with in bytes for the y plane. the value has to be rounded up to the next 64-bit word. offset 0x10 e20c layer source address b (packed/semi planar y) 31:28 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-55 27:0 layer n source address b r/w 0 layer n source data start address b in bytes. this sets starting address b for data transfers from the linear frame buffer memory to layer n. for semi planar and planar modes this address points to the y plane. note: it should be aligned on a 128-byte boundary. it has to be 8-byte aligned. offset 0x10 e210 layer source pitch b (packed/semi planar y) 31:23 unused - 22:0 layer n pitch b r/w 0 layer n source data pitch b in bytes sets pitch b for data transfers from the linear frame buffer memory to layer n. for semi planar and planar modes this determines the pitch for the y plane. the value has to be rounded up to the next 64-bit word. offset 0x10 e214 dummy pixel count 31:8 unused - 7:0 dcnt r/w 0 number of dummy pixels to be inserted between layer video lines offset 0x10 e218 layer source address a (semi planar uv) 31:28 unused - 27:0 layer source address a semi planar uv r/w 0 layer n source data start address a in bytes. this sets starting address a for data transfers from the linear frame buffer memory to layer n. this register holds the source address for the uv plane in semi planar modes. note: it should be aligned on a 128-byte boundary. it has to be 8-byte aligned. offset 0x10 e21c layer source address b (semi planar uv) 31:28 unused - 27:0 layer source address b semi planar uv r/w 0 layer n source data start address b in bytes. this sets starting address b for data transfers from the linear frame buffer memory to layer n. this register holds the source address for the uv plane in semi planar modes. note: it should be aligned on a 128-byte boundary. it has to be 8-byte aligned. offset 0x10 e220 line increment (packed) 31:16 unused - 15:0 line increment packed r/w 0xffffh this register determines whether a layer line is repeatedly fetched from memory or not. round down(2 16 /(line increment packed))= #of times the same line is fetched i.e., 0x8000h would fetch each line exactly twice (line doubling). offset 0x10 e224 line increment (semi planar) 31:16 unused - 15:0 line increment semi planar r/w 0xffffh this register determines whether a layer line is repeatedly fetched from memory or not. round down(2 16 /(line increment semi planar))= #of times the same line is fetched i.e., 0x8000h would fetch each line exactly twice (line doubling). offset 0x10 e228 layer source pitch (semi planar uv) table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-56 31:23 unused - 22:0 layer n pitch semi planar r/w 0 layer n source data pitch in bytes. this sets pitch for data transfers from the linear frame buffer memory to layer n for semi planar modes. the value is used independent of whether buffer a or b is used. the value has to be rounded up to the next 64-bit word. offset 0x10 e22c layer source width (semi planar uv) 31:23 unused - 12:0 layer n source width semi planar r/w 0 layer n source width in bytes for semi planar modes. the value is used independent of whether buffer a or b is used. the value has to be rounded up to the next 64-bit word. offset 0x10 e230 layer start 31 fine r/w 0 fine positioning enable for interlaced modes (layer size needs to be set to odd + even number of lines). fine=0 : layernstarty is always relative to frame position, ie, layernstarty=100 will display the layer at stg_y_pos=100 position. fine=1 : layernstarty is always relative to ?ld position, ie. layernstarty=100 will be translated to display layer at stg_y_pos=100/2=50 position. fine=1 is recommanded in interlaced mode. fine=0 is recommanded in progressive mode. 30:29 unused - 28:16 layernstartx r/w 0 layer n start x position (from zero at left edge) in pixels. negative x start position is possible. 15:13 unused - 12:0 layernstarty r/w 0 layer n start y position (from zero at top) in lines. negative y position is allowed. note: in interlaced modes the following rules apply: fine=0 : layernstarty is always relative to frame position i.e., layernstarty=100 will display the layer at stg_y_pos=100 position. fine=1 : layernstarty is always relative to ?ld position i.e., layernstarty=100 will be translated to display layer at stg_y_pos=100/2=50 position. fine=1 is recommanded in interlaced mode. fine=0 is recommanded in progressive mode. whenever layer y position is changed, please make sure other y position sensitive register settings are still satis?d, such as : start fetch register 10e2c8, shadow reload position 10e1f0 layer start ?ld register 10e23c (for interlaced mode) offset 0x10 e234 layer size 31:28 unused - 27:16 layernheight r/w 0 layer n height in lines. 15:12 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-57 11:0 layernwidth r/w 0 initial (before scaling) layer n width, in pixels. offset 0x10 e238 pedestal and o/p format 31:24 pedestal_up r/w 0 pedestal to be added to upper input (pedestal_up is a 2s complement number from -128 to 127) the pedestal removal is performed after the color key unit, before dithering. 23:16 pedestal_mid r/w 0 pedestal to be added to middle input (pedestal_mid is a 2s complement number from -128 to 127) the pedestal removal is performed after the color key unit, before dithering 15:8 pedestal_low r/w 0 pedestal to be added to lower input (pedestal_low is a 2s complement number from -128 to 127) the pedestal removal is performed after the color key unit, before dithering 7:3 unused - 2:1 op_format r/w 0 output type selector 0 = data expansion from 8 to 9 bit through multiply by two (zero in lsb) 1 = data expansion from 8 to 9 bit through multiply by two (msb in lsb position) 2,3 = data expansion from 8 to 9 bit through multiply by two (undither operation) 0 frmt_4xx r/w 0 input format indicator 0 = input is in 4:4:4 format 1 = input is in 4:2:2 format offset 0x10 e23c layer pixel processing 31:6 unused - 5 buffer toggle r/w 0 this bit controls the dma buffer mode: 1 = always toggle between buffer a and b (a=odd ?ld, b=even ?ld). 0 = no buffer toggle, always fetch from buffer spec a. 4 layer_start_field r/w 1 field in which the layer gets actually enabled once the layern_enable bit is set. this bit is used to invert the internal odd/ even signal. if the result of the operation layer_start_field xor oe is true the layer is enabled, otherwise the layer stays disabled until the oe signal changes. in non-interlaced modes: this bit must be set to 1?1 since the internal odd/even signal is forced to zero. in interlaced modes: layernstarty (0x10,e230) >= 0, set this bit to 0 layernstarty (0x10,e230) < 0, set this bit to 1 3 premult r/w 0 if this bit is set, the incoming pixels are premultiplied with alpha. that disables the new x alpha multiplication in the mixer stage if alpha blending is enabled. table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-58 2 alpha_use r/w 0 controls which alpha value is used for blending in the layer mixer stage 1 = use previous alpha 0 = use alpha of current layer 1 422:444_interspersed r/w 0 chroma upsample ?ter operation mode 1 = use this mode if input samples are arranged interspersed 0 = use this mode if input samples are arranged co-sited 0 422:444_enable r/w 0 chroma upsample ?ter enable 1 = chroma upsample ?ter is enabled 0 = chroma upsample ?ter is in bypass mode offset 0x10 e240 layer status/control 31:10 unused - 9 layer upload r - this bit indicates if the register upload into the shadow area is still in progress. 1 = new register upload possible, previous upload is complete 0 = upload in progress, do not reprogram any registers as the results are undetermined 8:1 unused - 0 layern_enable r/w 0 0 = disable layer n 1 = enable layer n this register reads always 0 if the screen timing generator is not enabled offset 0x10 e244 lut programming 31:24 alpha r/w 0 alpha value for lut programming 23:16 red r/w 0 red value for lut programming 15:8 green r/w 0 green value for lut programming 7:0 blue r/w 0 blue value for lut programming offset 0x10 e248 lut addressing 31:24 lutaddress r/w 0 address register for lut programming, no auto-increment is supported. 23:9 unused - 8 host_enable r/w 0 this enables read/write access by the host: 1 = host access enabled. 0 = host access disabled. 7:2 unused - 1 lut_enable r/w 0 lut enable signal 0 = bypass lut 1 = allow data to ?w through lut 0 unused - offset 0x10 e24c pixel key and register 31:24 pixelkeyand r/w 0xff the bits 31:24 in 32 bpp mode are anded with this mask (input for key2). not available when pf_10b_mode(see 0x10 e2bc)is on. table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-59 23:0 unused - offset 0x10 e250 color key1 and mask 31:24 unused - 23:0 colorkeyand1 r/w 0xfffff f de?es a 24-bit mask where the pixel is anded before its keyed with the colorkeyand value. offset 0x10 e254 color key up1 31:24 unused - 23:0 colorkeyup1 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e258 color key low1 31:24 unused - 23:0 colorkeylow1 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e25c color key replace1 31 colorkeyreplaceen r/w 0 enables color replacement. 30:24 unused - 23:0 colorkeyreplace1 r/w 0 de?es a 24-bit color to be put into the data path if the color key matches. the data format to be used is an expanded 24-bit rgb/yuv format. if the data was fetched unsigned from memory, an unsigned value has to be used. signed pixel data formats in memory require signed values in this register. offset 0x10 e260 color key2 and mask 31:24 unused - 23:0 colorkeyand2 r/w 0xfffff f de?es a 24-bit mask where the pixel is anded before its keyed with the colorkey value. offset 0x10 e264 color key up2 31:24 unused - 23:0 colorkeyup2 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e268 color key low2 31:24 unused - 23:0 colorkeylow2 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e26c color key replace2 31 colorkeyreplaceen r/w 0 enables color replacement. 30:24 unused - 23:0 colorkeyreplace2 r/w 0 de?es a 24-bit color to be put into the data path if the color key matches. the data format to be used is an expanded 24-bit rgb/yuv format. if the data was fetched unsigned from memory, an unsigned value has to be used. signed pixel data formats in memory require signed values in this register. offset 0x10 e270 color key3 and mask 31:24 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-60 23:0 colorkeyand3 r/w 0xfffff f de?es a 24-bit mask where the pixel is anded before its keyed with the colorkey value. offset 0x10 e274 color key up3 31:24 unused - 23:0 colorkeyup3 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e278 color key low3 31:24 unused - 23:0 colorkeylow3 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e27c color key replace3 31 colorkeyreplaceen r/w 0 enables color replacement. 30:24 unused - 23:0 colorkeyreplace3 r/w 0 de?es a 24-bit color to be put into the data path if the color key matches. the data format to be used is an expanded 24-bit rgb/yuv format. if the data was fetched unsigned from memory, an unsigned value has to be used. signed pixel data formats in memory require signed values in this register. offset 0x10 e280 color key4 and mask 31:24 unused - 23:0 colorkeyand4 r/w 0xfffff f de?es a 24-bit mask where the pixel is anded before its keyed with the colorkey value. offset 0x10 e284 color key up4 31:24 unused - 23:0 colorkeyup4 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e288 color key low4 31:24 unused - 23:0 colorkeylow4 r/w 0 de?es a 24-bit color key used for color keying inside the layer. offset 0x10 e28c color key replace4 31 colorkeyreplaceen r/w 0 enables color replacement. 30:24 unused - 23:0 colorkeyreplace4 r/w 0 de?es a 24-bit color to be put into the data path if the color key matches. the data format to be used is an expanded 24-bit rgb/yuv format. if the data was fetched unsigned from memory, an unsigned value has to be used. signed pixel data formats in memory require signed values in this register. offset 0x10 e290 color key mask/rop 31:24 unused - 23:20 colorkeymask r/w 0 this mask speci?s which color to key in for the current pixel coming out of the layer. 19:16 colorkeymaskp r/w 0 this color mask is used to decide which color key to use for the incoming previous pixel. table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-61 15:8 unused - 7:6 passcolorkey3 r/w 0 this register determines how to handle color key forwarding 00 pass zeros to the next mixer 01 pass current color key 3 to next mixer 10 pass previous color key 3 to next mixer 11 reserved 5:4 passcolorkey2 r/w 0 this register determines how to handle color key forwarding 00 pass zeros to the next mixer 01 pass current color key 2 to next mixer 10 pass previous color key 2 to next mixer 11 reserved 3:2 passcolorkey1 r/w 0 this register determines how to handle color key forwarding 00 pass zeros to the next mixer 01 pass current color key1 to next mixer 10 pass previous color key1 to next mixer 11 reserved 1:0 passcolorkey0 r/w 0 this register determines how to handle color key forwarding 00 pass zeros to the next mixer 01 pass current color key 0 to next mixer 10 pass previous color key 0 to next mixer 11 reserved offset 0x10 e294 pixel invert/select rop 31:16 invertrop r/w 0 this rop decides if the previous pixel is inverted or not. rop output: 1 = invert previous pixel. 0 = do not invert previous pixel. 15:0 selectrop r/w 0 this rop determines which pixel to select for the current mixer output. rop output: 1 = select previous pixel. 0 = select new pixel. offset 0x10 e298 alpha blend/key pass 31:16 alphablend r/w 0 this rop value determines whether or not to do an alpha blend. rop output: 1 = do alpha blending. 0 = no alpha blending 15:0 keypass r/w 0 this rop generates the key which is passed to the next layer mixer and is used as key0 in those rops. offset 0x10 e29c alpha pass 31:16 alphapass r/w 0 this rop value determines which alpha is passed to the next mixer stage. rop output: 1 = alpha of previous pixel 0 = alpha of current pixel 15:0 unused - offset 0x10 e2a0 color key rops 1/2 31:16 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-62 15:8 colorkeyrop1 r/w 0 this rop determines if results of component color keying are true or not. keys to the rop are range_match upper, middle, lower. upper match is key2, middle match is key1, lower match is key0. 0 = color key didn? match. 1 = color key matched. 7:0 colorkeyrop2 r/w 0 this rop determines if results of component color keying are true or not. keys to the rop are range_match upper, middle, lower. upper match is key2, middle match is key1, lower match is key0. 0 = color key didn? match. 1 = color key matched. offset 0x10 e2a4 color key rops 3/4 31:16 unused - 15:8 colorkeyrop3 r/w 0 this rop determines if results of component color keying are true or not. keys to the rop are range_match upper, middle, lower. upper match is key2, middle match is key1, lower match is key0. 0 = color key didn? match. 1 = color key matched. 7:0 colorkeyrop4 r/w 0 this rop determines if the results of component color keying are true or not. keys to the rop are range_match upper, middle, lower. upper match is key2, middle match is key1, lower match is key0. 0 = color key didn? match. 1 = color key matched. offset 0x10 e2a8 intr 31:22 unused - 21:16 pcoeff r/w - phase coef?ient 15:12 unused - 11:0 dpcoeff r/w - differential phase coef?ient for the interpolator to work in bypass mode this register has to be programmed to 0 offset 0x10 e2ac hsru phase 31:28 unused - 27:16 hsru_d_phase r/w 0 unsigned. this delta phase is added with phase with every output data. once phase is added with a certain number of d_phases to get over?wed, then its time shift input sample signals. for the hsru to work in bypass mode this register has to be programmed to 0. example: 8000 (hex) => upscaling by 2 4000 (hex) => upscaling by 4 15:7 unused - 5:0 hsru_phase r/w 0 unsigned. this is the initial phase of input pixel phase. it determines the portions of the ?st input samples used to generate output pixels. offset 0x10 e2b0 hsru delta phase 31:26 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-63 25:16 hsru_ddd_phase r/w 0 signed. this delta-delta-delta phase is added with delta-delta phase to make it change. this is used for non-linear scaling ratios.for the hsru to work in bypass mode this register has to be programmed to 0. 15:12 unused - 11:0 hsru_dd_phase r/w 0 signed. this is the initial delta-delta phase. it is added with delta phase to make it change. this is used for non-linear scaling ratios. for the hsru to work in bypass mode this register has to be programmed to 0. note: layer size(?al) register has to be modi?d if hsru scale ratio is changed. offset 0x10 e2b4 layer size (?al) 31:12 unused - 11:0 layernwidth r/w 0 ?al (after scaling) layer n width, in pixels. note : this register has to be programmed to match the ?al width after scaling, as given by the equation below. final width = (input width)*scaling ratio lint and hsru can only crop at most 5 pixels off a scaled image. setting this register to a width which is more than 5 pixels smaller than the scaled width can result in data under?w. on the other hand, if the ?al width is greater than the scaled image, the last pixel will be repeated to ?l the ?al width. always remember to update this register if lint or hsru scale values are changed. offset 0x10 e2b8 output and alpha manipulation 31:24 unused - 23:16 layer_fixed_alpha r/w 0 alpha blend value to be applied to mixer. provides 256 levels of ?ed alpha blending: the alphaselect rop must be set appropriately to use this feature. 15:14 pf_alpha_mode r/w control how alpha channel data is generated 00: fixed alpha 01: fixed alpha 10: per pixel alpha 11: per pixel alpha is multiplied with (?ed_alpha)/256 mode 11 is not effective when pf_10b_mode is on since the alpha value is set to zero. 13 unused 12 pf_a2c r/w 0 controls alpha channel format within layer 0 = data untouched 1 = data conversion twos compliment <-> binary offset the conversion takes place after the color key unit before the undither unit. table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-64 11 pf_u2c r/w 0 controls upper channel format within layer 0 = data untouched 1 = data conversion twos compliment <-> binary offset the conversion takes place after the color key unit before the undither unit. 10 pf_m2c r/w 0 controls middle channel format within layer 0 = data untouched 1 = data conversion twos compliment <-> binary offset the conversion takes place after the color key unit before the undither unit. 9 pf_l2c r/w 0 controls lower channel format within layer 0 = data untouched 1 = data conversion twos compliment <-> binary offset the conversion takes place after the color key unit before the undither unit 8:6 unused - 5:3 pf_offset2 r/w 0 de?es pixel offset (in bytes) within a multi-pixel 64-bit word for channel 2 for semi-planar and planar modes. 0, 2 or 4 for 10-bit yuv 4:2:2 semi-planar format 0 to 7 for 8-bit yuv 4:2:2 semi-planar format the number will be truncated to the closest even number for channel 2 2:0 pf_offset1 r/w 0 de?es pixel offset (in bytes) within a multi-pixel 64-bit word. 0, 2 or 4 for 10-bit yuv 4:2:2 semi-planar format 0 or 4 for 10-bit (20 bpp) packed yuv 4:2:2 format 0, 2, 4 or 6 for 8-bit (16 bpp) packed yuv 4:2:2 or 16-bit varible format 0 or 4 for 32-bit varible format 0 to 7 for all the other formats offset 0x10 e2bc formats 31:14 unused - 13 pf_endian r/w 0 input format endian mode 0: same as system endian mode 1: opposite of system endian mode not available when pf_10b_mode is on. 12 unused 11:10 pf_pix_mode r/w 0 pixel key output modes 00: both keys ? 01: bits [1:0] of v/b output 10: key 2 bit [7] of alpha output 11: key 2 and of pixel key and alpha is not zero mode 11 is not available when pf_10b_mode is on. 9 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-65 8 pf_10b_mode r/w 0 10-bit input format modes 0: 8-bit input format mode 1: 10-bit input format mode 7:0 pf_ipfmt r/w 0 input formats 08 (hex) = yuv 4:2:2 semi-planar 24 (hex) = 1-bit indexed note1 45 (hex) = 2-bit indexed note1 66 (hex) = 4-bit indexed note1 87 (hex) = 8-bit indexed note1 a0 (hex) = packed yuy2 4:2:2 a1 (hex) = packed uyvy 4:2:2 ac (hex) = 16 bits variable contents 4:4:4 cc (hex) = 24 bits variable contents 4:4:4 e8 (hex) = 32 bits variable contents 4:2:2 ec (hex) = 32 bits variable contents 4:4:4 note1: for indexed modes variable format register should be set ?7e7e7e7 note 2 : only yuv 4:2:2 semi-plana format (08) and packed formats (a0 & a1) are available when pf_10b_mode is on offset 0x10 e2c0 layer background color 31 bg_enable r/w 0 this bit enables the replacement of the previous input by the speci?d background color. 1 = replace 0 = use previous mixer output. 30:24 unused - 23:16 upper r/w 0 upper channel of the background color (r/y) (twos complement) 15:8 middle r/w 0 middle channel of the background color (g/u) (twos complement) 7:0 lower r/w 0 lower channel of the background color (b/v) (twos complement) offset 0x10 e2c4 variable format register 31:29 pf_size_a[2:0] r/w 0 size component for alpha number of bits minus 1 (e.g. 7 => 8 bits per component) not available when pf_10b_mode is on. 28:24 pf_offs_a[4:0] r/w 0 offset component for alpha index of msb position within 32-bit word (0-31) not available when pf_10b_mode is on. 23:21 pf_size_l[2:0] r/w 0 size component for v or b number of bits minus 1 (e.g. 7 => 8 bits per component) not available when pf_10b_mode is on. 20:16 pf_offs_l[4:0] r/w 0 offset component for v or b index of msb position within 32-bit word (0-31) not available when pf_10b_mode is on. 15:13 pf_size_m[2:0] r/w 0 size component for u or g number of bits minus 1 (e.g. 7 => 8 bits per component) not available when pf_10b_mode is on. 12:8 pf_offs_m[4:0] r/w 0 offset component for u or g index of msb position within 32-bit word (0-31) not available when pf_10b_mode is on. table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-66 7:5 pf_size_u[2:0] r/w 0 size component for y or r number of bits minus 1 (e.g. 7 => 8 bits per component) not available when pf_10b_mode is on. 4:0 pf_offs_u[4:0] r/w 0 offset component for y or r index of msb position within 32-bit word (0-31) not available when pf_10b_mode is on. offset 0x10 e2c8 start fetch 31 enable r/w 0 set this bit to delay the dma data fetch timing until line number speci?d in bit 11:0 is reached. if disabled, dma will pre-fetch data for the next ?ld at the end of current ?ld. 27:16 flushcount r/w 0x30h the number of ?sh pixels to be inserted after the end of a ?ld. if start fetch is enabled this register must contain a large enough value to ?sh all pixels out of the pipeline after the last pixel entered the pixel formatter. (approx. 50) 15:12 unused r/w - 11:0 fetch start r/w 0 if enabled (by setting bit 31 to 1), the data fetched from memory will be delayed until line number set here is reached, ie. the data pre- fetch is disabled. the number given here must be set to a value earlier in y position than layernstarty in 10e230 to prevent from layer under?w. in non-interlaced mode : this value is relative to frame position. for example, if layernstarty=100, a start fetch position of 98 is deemed earlier position. in interlaced mode: this value is relative to field position. for example, if layernstarty=100, a start fetch position of 52 is deemed one line too late to start the fetch, because layernstarty=100 is equivalent to ?ld position 100/2=50. therefore, a start fetch positon of 48 is a proper one. offset 0x10 e2cc brightness & contrast 31:29 unused - 28 vcbm_u2b r/w 0 brightness control bit for upper channel. vcbm_u2b = 1 if brightness control is activated for the upper channel. 27 vcbm_m2b r/w 0 brightness control bit for middle channel. vcbm_m2b = 1 if brightness control is activated for the middle channel. 26 vcbm_l2b r/w 0 brightness control bit for lower channel. vcbm_l2b = 1 if brightness control is activated for the lower channel. table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-67 25:16 vcbm_brightness r/w 0 brightness setting (signed value ranging from -512 to 511 which is equivalent to -100% to +100% brightness change for nominal signals having a range from -256 to 255 with a contrast setting of 256) nominal value: 0 brightness control is performed after e color space conversion in associated with the contrast control. y?= y?+ vcbm_brightness if vcbm_u2b ?g is raised. 15 vcbm_u2c r/w 0 twos complement to binary offset conversion for contrast control (upper channel y?r?= y/r + vcbm_blk_offset) needs to be set in case the data format entering the vcbm is yuv or rgb 14 vcbm_m2c r/w 0 twos complement to binary offset conversion for contrast control (middle channel u/g) needs to be set in case the data format entering the vcbm is rgb 13 vcbm_l2c r/w 0 twos complement to binary offset conversion for contrast control (lower channel v/b) needs to be set in case the data format entering the vcbm is rgb. 12 vcbm_u2co r/w 0 back-end reverse offset (for twos complement mentioned above) control bit for upper channel. (yout/rout = yout/rout - vcbm_blk_offset described below) 11 vcbm_m2co r/w 0 back-end reverse offset (for twos complement mentioned above) control bit for middle channel 10 vcbm_l2co r/w 0 back-end reverse offset (for twos complement mentioned above) control bit for lower channel 9:0 vcbm_blk_offset r/w 0x100 signed 10-bit two's complement to binary offset (or black-level offset). +256 is the default value. offset 0x10 e2d0 matrix coef?ients 1 31:27 unused - 26:16 c_11 r/w 0x100 color space conversion matrix coef?ient - c11 matrix component 15:11 unused - 10:0 c_12 r/w 0 color space conversion matrix coef?ient - c12 matrix component offset 0x10 e2d4 matrix coef?ients 2 31:27 unused - 26:16 c_13 r/w 0 color space conversion matrix coef?ient - c13 matrix component 15:11 unused - 10:0 c_21 r/w 0 color space conversion matrix coef?ient - c21 matrix component offset 0x10 e2d8 matrix coef?ients 3 31:27 unused - 26:16 c_22 r/w 0x100 color space conversion matrix coef?ient - c22 matrix component 15:11 unused - 10:0 c_23 r/w 0 color space conversion matrix coef?ient - c23 matrix component offset 0x10 e2dc matrix coef?ients 4 31:27 unused - table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-68 26:16 c_31 r/w 0 color space conversion matrix coef?ient - c31 matrix component 15:11 unused - 10:0 c_32 r/w 0 color space conversion matrix coef?ient - c32 matrix component offset 0x10 e2e0 matrix coef?ients 5 31:27 unused - 26:16 c_33 r/w 0x100 color space conversion matrix coef?ient - c33 matrix component 15:10 unused - 9 div_by_512 r/w 0 matrix coef?ient fraction precision setting 0 = 8-bit fraction format; matrix product is divided by 256. 1 = 9-bit fraction format; matrix product is divided by 512. 8 vcbm_enable r/w 0 operate on inputs or bypass block 0 = bypass block 1 = allow data ?w through block 7:0 unused - offset 0x10 e2e8 lshr_par_0 31 enable_lshr r/w 0 enable or disable lshr, if disable lshr will operate in bypass mode. 30:24 hdp_coring_thr r/w 0 hdp coring threshold coring threshold for hdp adjustment (0..127) 23:21 hdp_neg_gain r/w 0 hdp negative overshoot adjustment factor look-up table step size adjustment factor for negative overshoots (0..4) 20:18 hdp_delta r/w 0 hdp lut step size factor step size factor for hdp look-up table (0..4) 17:14 hdp_hpf_gain r/w 0 hdp hpf ?ter gain weighting factor for hpf ?ter in hdp (0..15: sum of hdp ?ter gains must be 32 or less) 13:10 hdp_bpf_gain r/w 0 hdp bpf ?ter gain weighting factor for bpf ?ter in hdp (0..15: sum of hdp ?ter gains must be 32 or less) 9:6 hdp_epf_gain r/w 0 hdp epf ?ter gain weighting factor for epf ?ter in hdp (0..15: sum of hdp ?ter gains must be 32 or less) 5:3 kappa r/w 0 epf ?ter selector determines response of epf ?ter (0,1,2,4) 2 enable_lti r/w 0 enable luma transient improvement 1:include lti; 0:not lti 1 enable_cds r/w 0 enable color dependent sharpness 1:include cds; 0:not cds 0 enable_hdp r/w 0 enable horizontal dynamic peaking 1:include hdp; 0:not hdp offset 0x10 e2ec lshr_par_1 31:26 cds_coring_thr r/w 0 cds coring threshold coring threshold for cds adjustment (0..63) table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-69 25:22 cds_gain r/w 0 cds gain factor strength of cds adjustment (0..15) 21:18 cds_slope r/w 0 cds transition slope determines size in uv plane of cds adjustment transition from onset to maximum (0..15) 17:14 cds_area r/w 0 cds onset area determines location in uv plane of onset of cds adjustment (0..15) 13 unused - 12:9 hdp_lut_gain r/w 0 hdp lut gain factor gain factor for hdp look-up table scaling (0..15) 8:0 unused - offset 0x10 e2f0 lshr_par_2 31 wide_format r/w 0 wide format modeswitches internal ?ters, adapting to narrow and wide output horizontal resolutions 0:less than or equal to 1280 pixels per line 1: greater than 1280 pixels per line 30:19 unused - 18:12 lti_coring_thr r/w 0 lti coring threshold coring threshold for lti adjustment (0..127) 11:8 lti_hpf_gain r/w 0 lti hpf ?ter gain weighting factor for hpf ?ter in lti(0..15;sum of lti ?ters gain must be 32 or less) 7:4 lti_bpf_gain r/w 0 lti bpf ?ter gain weighting factor for bpf ?ter in lti(0..15;sum of lti ?ters gain must be 32 or less) 3:0 lti_epf_gain r/w 0 lti epf ?ter gain weighting factor for epf ?ter in lti(0..15;sum of lti ?ters gain must be 32 or less) offset 0x10 e2f4 lshr_par_3 31:30 energy_sel r/w 0 energy measurement sharpening ?ter selector 0: hpf (maximum), 4*hpf(sum); 1: bpf; 2: epf; 3: hpf; 29:25 unused - 24:18 lti_max_gain r/w 0 lti gain factor limit maximum lti gain factor (0..127) 17:14 lti_steep_gain r/w 0 lti gain factor steepness slope slope of steepness in?ence on lti gain factor (0..15) 13:6 lti_base_gain r/w 0 lti basic gain factor basic lti gain (strength) factor, no steepness(-128..127) 5:3 lti_steep_taps r/w 1 lti luma steepness ?ter width single-sided width of lti luma steepness ?ter (1..7) 2:0 lti_minmax_taps r/w 1 lti luma minimum, maximum ?ter width single-sided widths of lti luma minimum and maximum ?ters (1..7) table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-70 offset 0x10 e2f8 lshr_e_max 31:10 unused - 9:0 lshr_e_max r 0 statistics on one of the sharpness ?ter max measurement value = 10bu offset 0x10 e2fc lshr_e_sum 31:26 unused - 25:0 lshr_e_sum r 0 statistics on one of the sharpness ?ter sum of abs max energy value = 26bu offset 0x10 e300 lshr measurement window start 31:27 reserved 26:16 lshr_mw_start_y r/w 0 lshr measurement window start line (the ?st line included in the measurement window, the layer start position is (0,0)). 15:11 reserved 10:0 lshr_mw_start_x r/w 0 lshr measurement window start pixel offset 0x10 e304 lshr measurement window end 31:27 reserved 26:16 lshr_mw_end_y r/w 7ff lshr measurement window end line (the last line included in the measurement window) 15:11 reserved 10:0 lshr_mw_end_x r/w 7ff lshr measurement window end pixel offset 0x10 e320 layer solid color 31 sc_enable r/w 0 this bit enables the replacement of the layer input by the speci?d color. 1 = replace 0 = use layer input 30:24 unused - 23:16 upper r/w 0 upper channel of the replacement color (r/y) (twos complement) 15:8 middle r/w 0 middle channel of the replacement color (g/u) (twos complement) 7:0 lower r/w 0 lower channel of the replacement color (b/v) (twos complement) offset 0x10 e324 layer lut-hist bins 00 to 03 31:24 bin03 r/w 0 8-bit signed offset from a yout=yin curve for yin=-192+ped register 23:16 bin02 r/w 0 8-bit signed offset from a yout=yin curve for yin=-208+ped register 15:8 bin01 r/w 0 8-bit signed offset from a yout=yin curve for yin=-224+ped register 7:0 bin00 r/w 0 8-bit signed offset from a yout=yin curve for yin=-240+ped register offset 0x10 e328 layer lut-hist bins 04 to 07 31:24 bin07 r/w 0 8-bit signed offset from a yout=yin curve for yin=-128+ped register 23:16 bin06 r/w 0 8-bit signed offset from a yout=yin curve for yin=-144+ped register 15:8 bin05 r/w 0 8-bit signed offset from a yout=yin curve for yin=-160+ped register 7:0 bin04 r/w 0 8-bit signed offset from a yout=yin curve for yin=-176+ped register table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-71 offset 0x10 e32c layer lut-hist bins 08 to 011 31:24 bin11 r/w 0 8-bit signed offset from a yout=yin curve for yin=-64+ped register 23:16 bin10 r/w 0 8-bit signed offset from a yout=yin curve for yin=-80+ped register 15:8 bin09 r/w 0 8-bit signed offset from a yout=yin curve for yin=-96+ped register 7:0 bin08 r/w 0 8-bit signed offset from a yout=yin curve for yin=-112+ped register offset 0x10 e330 layer lut-hist bins 12 to 15 31:24 bin15 r/w 0 8-bit signed offset from a yout=yin curve for yin= 0+ped register 23:16 bin14 r/w 0 8-bit signed offset from a yout=yin curve for yin=-16+ped register 15:8 bin13 r/w 0 8-bit signed offset from a yout=yin curve for yin=-32+ped register 7:0 bin12 r/w 0 8-bit signed offset from a yout=yin curve for yin=-48+ped register offset 0x10 e334 layer lut-hist bins 16 to 19 31:24 bin19 r/w 0 8-bit signed offset from a yout=yin curve for yin=64+ped register 23:16 bin18 r/w 0 8-bit signed offset from a yout=yin curve for yin=48+ped register 15:8 bin17 r/w 0 8-bit signed offset from a yout=yin curve for yin=32+ped register 7:0 bin16 r/w 0 8-bit signed offset from a yout=yin curve for yin=16+ped register offset 0x10 e338 layer lut-hist bins 20 to 23 31:24 bin23 r/w 0 8-bit signed offset from a yout=yin curve for yin=128+ped register 23:16 bin22 r/w 0 8-bit signed offset from a yout=yin curve for yin=112+ped register 15:8 bin21 r/w 0 8-bit signed offset from a yout=yin curve for yin=96+ped register 7:0 bin20 r/w 0 8-bit signed offset from a yout=yin curve for yin=80+ped register offset 0x10 e33c layer lut-hist bins 24 to 027 31:24 bin27 r/w 0 8-bit signed offset from a yout=yin curve for yin=192+ped register 23:16 bin26 r/w 0 8-bit signed offset from a yout=yin curve for yin=176+ped register 15:8 bin25 r/w 0 8-bit signed offset from a yout=yin curve for yin=160+ped register 7:0 bin24 r/w 0 8-bit signed offset from a yout=yin curve for yin=144+ped register offset 0x10 e340 layer lut-hist bins 28 to 31 31:24 bin31 r/w 0 8-bit signed offset from a yout=yin curve for yin=256+ped register 23:16 bin30 r/w 0 8-bit signed offset from a yout=yin curve for yin=240+ped register 15:8 bin29 r/w 0 8-bit signed offset from a yout=yin curve for yin=224+ped register 7:0 bin31 r/w 0 8-bit signed offset from a yout=yin curve for yin=208+ped register offset 0x10 e344 layer histogram control 31:14 unused - 13 enable r/w 0 histogram and black stretch enabled 1 = enabled 0 = bypassed table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-72 12:11 uv_gain r/w 2 gain factor for uv correction 00 = factor of 0 01 = factor of 0.5 10 = factor of 1 11 = factor of 2 10 uv_pos r/w 1 uv corrections only in positive direction 9 ratio_limit r/w 1 minimum denominator for uv processing 0 = denominator larger than or equal to 64 1 = denominator larger than or equal to 128 8 round r/w 0 round or truncate in interpolation for y transfer function 1 = round 0 = truncate 7:0 black_off r/w 0 8-bit signed offset for black stretch value this is the 33rd histogram variable and this is the only way to add an offset from a yout=yin curve for yin= -256+ped register. but it affects all other 32 values too. offset 0x10 e348 layer cftr blue 31:25 unused - 24 blueycomp r/w 1 compensate y in order to prevent illegal colors in rgb space 1 = y compensation on 0 = y compensation off 23:20 bluegain r/w a strength of blue stretch effect (0..15) higher value = greater effect 19:17 bluesize r/w 4 blue stretch detection area (0..7) lower value = greater detection area 16 blue_enable r/w 0 blue stretch functionality 1 = enable 0 = bypass 15:9 unused - 8:6 skingain r/w 2 strength of skin tone correction effect (0..4) higher value greater effect 5:3 skintone r/w 2 direction of correction (0..4), lower value = towards ?ellow?higher value = towards ?ed 2:1 skinsize r/w 1 skin tone detection area size (0..2) higher value = greater detection area 0 skin_enable r/w 0 skin tone correction functionality 1 = enable 0 = bypass offset 0x10 e34c layer cftr green 31:15 unused - 14:11 greenmax r/w 9 maximum correction(0..15), higher value = stronger correction allowed 10:8 greensat r/w 4 green detection area maximum saturation (0..7) higher value = effect extends to higher saturations table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-73 7:4 greengain r/w 7 strength of green enhancement effect (0..15) higher value = greater effect 3:1 grrensize r/w 0 green detection area minimum saturation (0..7) lower value = greater detection area 0 green_enable r/w 0 enable green enhancement functionality 1 = enable 0 = bypass offset 0x10 e350 layer dcti control 31:16 unused - 15 superhill r/w 1 superhill mode, avoid discolorations in transients within a colour component. 14:11 threshold r/w 4 immunity against noise 10 separate r/w 0 common or separate processing of u and v signals 1 = separate 0 = common (1 is the recommended value as it works better) 9 protection r/w 1 hill protection mode, no discolorations in narrow colour gaps 8:6 limit r/w 7 limit for pixel shift range 0-6 = (limit+1)*2 7 = 15 5:2 gain r/w 8 gain factor on sample shift gain/16 (0/16..15/16) 1 ddx_sel r/w 1 selection of simple or improved ?st differentiating ?ter 1 = improved 0 = simple 0 enable r/w 0 enable dcti functionality 1 = enable dcti 0 = bypass dcti offset 0x10 efe0 interrupt status qvcp 31:12 unused - 11 layer_done r 0 the layer has been completely displayed (layer 2) 10 buf_done r 0 dma channel is done fetching all data for the current layer (layer 2) 9 fcu_underflow r 0 under?w in fcu fifo for layer 2 8 unused 7 layer_done r 0 the layer has been completely displayed (layer 1) 6 buf_done r 0 dma channel is done fetching all data for the current layer (layer 1) 5 fcu_underflow r 0 under?w in fcu fifo for layer 1 4 unused 3 vintb r 0 vertical line interrupt issued if y position matches vlintb 2 vinta r 0 vertical line interrupt issued if y position matches vlinta 1 vbi_done_int r 0 vbi/register load is done with the current packet list table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 11: qvcp 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 11-74 0 vbi_packet_int r 0 vbi/register reload has sent a packet with the irq request bit set in the packet header offset 0x10 efe4 interrupt enable qvcp 31:24 unused - 23:0 interrupt enables r/w 0 a ??in the appropriate bit will enable the interrupt according to the speci?ation in register 0xfe0. offset 0x10 efe8 interrupt clear qvcp 31:24 unused - 23:0 interrupt clears w 0 a ??in the appropriate bit will clear the interrupt according to the speci?ation in register fe0. offset 0x10 efec interrupt set qvcp 31:24 unused - 23:0 interrupt sets w 0 a ??in the appropriate bit will set the interrupt according to the speci?ation in register fe0. offset 0x10 eff4 powerdown 31 powerdown r 0 this bit has no effect i.e., there is no powerdown implemented for this module. 30:0 unused - offset 0x10 effc module id 31:16 module id r 0xa052 unique revision number 15:12 rev_major r 0 major revision counter 11:8 rev_minor r 1 minor revision counter 7:0 app_size r 00 aperture size 0 = 4 kb table 20: qvcp 1 registers ?ontinued bit symbol acces s value description
1. introduction the video input processor (vip) handles incoming digital video and processes it for use by other components of the pnx15xx series. this enables applications such as picture-in-picture and video teleconferencing on the tv screen. 1.1 features the vip provides the following functions: receives digital video data from the video port. the data stream may come from a device such as the tda8751, which can digitize analog video from any source and convert a digital signal from a dvi interface/source into parallel yuv format features 8/10-bit single channel (single-stream) and 16/20-bit dual channel (dual-stream) capture of ccir601 yuv 4:2:2 video input with embedded or explicit syncs, supported by a maximum clock frequency of 81 mhz. the dual_stream mode is used to capture a 16 or 20-bit hd stream where 8/10- bit y and 8/10-bit multiplexed u/v data are received and captured on two separate channels. provides video and auxiliary (aux, anc, or raw) data acquisition and capture. provides separate acquisition windows for video and for vbi data (cannot be used if the output format is planar data. implements two identical dither units capable of either dithering or rounding 9- or 10-pixel components in video mode. enables raw data capture in either 8 or 10 bits for single_stream mode and 8 bits of dual_stream mode. enables anc header decoding or window mode for vbi data extraction. performs horizontal scaling, cropping and pixel packing on video data from a continuous video data stream or a single ?ld or frame. performs horizontal down-scaling or zoom-up by 2x, the upscaling being possible only in the single-stream mode. enables linear horizontal aspect ratio conversion using normal or transposed 6-tap polyphase ?ter. enables non-linear horizontal aspect ratio conversion using normal 6-tap polyphase ?ter. chapter 12: video input processor pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-2 permits optional linear phase interpolation / nonlinear phase interpolation (as in mbs). allows color-space conversion (mutually exclusive with scaling) on the video path. allows 4:2:2 to 4:4:4 conversions on the video path. provides last-pixel-in signals, for vbi and video data, to the gpio block for timestamping. features interrupt generation, for vbi or video data written to memory. provides an internal test pattern generator with ntsc, pal, and variable format support. features a wide variety of output formats such as planar yuv 4:4:4, planar yuv 4:2:2, planar rgb, semi-planar yuv 4:2:2 packed uyvy, etc. planar formats are mutually exclusive with the vbi capture. 2. functional description 2.1 vip block level diagram the main functional blocks of the vip and the primary data paths (not including syncs etc.) are shown in figure 1 . a brief description of each of the submodules is given in t ab le 1 . figure 1: simpli?d vip block diagram test pattern video timing control up sample down sample psu write dma 3 channel 64 64 64 8 8 8 10 10 16 10 10 8 8 16 horizontal poly phase fir pre-dither and post-dither 10 8 8 8 8 8 8 video extract aux data extract 10 10 input ports control table 1: vip submodule descriptions submodule brief description of functionality test pattern an internal generator that produces 4:2:2 ntsc/pal video streams video timing control this submodule receives incoming data samples from either the test pattern generator or the digital video port. a tally of the sample is maintained when it conforms to the itu-r 656 or itu-r 1364. video and aux samples are forwarded to video extract and aux data extract respectively. video extract video input pipe windower. this submodule: receives video samples from video port input module. captures desired samples in a programmable size rectangular area (window). forwards captured samples to the pre-dither unit.
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-3 2.2 chip i/o and connections figure 2 sketches the input pins of the vip module. refer to chapter 3 system on chip resources , section 7. on page 3- 16 for the mapping of the vip i/o signal with the pnx15xx series i/o pins. 2.2.1 data routing and video modes the vip can be operated in three different modes. sd video mode the interleaved data (yuv) is captured from the dv_data[9:0] input, also called channel a. the dv_d_data, also called channel b, is not used in the sd mode. hd mode the y data is expected on dv_d_data[9:0] (channel b) and u/v data is expected on dv_data[9:0] (channel a). raw mode in raw mode the data can be captured from channel a or b. pre-dither and post- dither there are two identical dither units: pre-dither and post-dither, capable of 10->9, 10->8 and 9->8 dithering/rounding of the video data only. the recommended mode is to have rounding for 10->9 and dithering for 9->8 up sample 4:2:2 to 4:4:4 interpolation fir filter for chroma upsampling 8-bit video samples are received from post-dither. horizontal poly phase fir horizontal scaler pipeline down sample 4:4:4 to 4:2:2 decimation fir filter for chroma down sampling aux data extract video input pipe aux windower. this submodule: receives aux samples from video port input module. captures desired samples in a programmable captured window and/or within a buffer space. captures anc packet with matching did captures all valid input samples forwards the captured samples to pixel packer. 3 channel write dma control an interface to the memory agent table 1: vip submodule descriptions ?ontinued submodule brief description of functionality figure 2: vip module interface dv_data[9:0] (channel a) dv_d_data[9:0] (channel b) vrefhd hrefhd frefhd vip
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-4 2.2.2 input timing a separate signal, dv_valid, is provided to validate all incoming data. the relationship between dv_valid and data, with reference to clock, is shown in figure 3 . 2.3 test pattern generator the test pattern generator produces a video stream with a pixel frequency of half the vip input clock e.g., the 27 mhz encoder clock by programming the clock selection block accordingly. the sync generation is ntsc-like, with 525 lines per frame and 858 pixels per line. the active video range is 720x462 bordered by a white frame. the test pattern is shown in figure 4 , and contains the following elements: a white 2-pixel wide frame?ize 720x462 a color bar?hite 100%, yellow 75%, cyan 75%, green 75%, magenta 75%, red 75%, blue 75%, and black 0%. a grey ramp?ull value range 0?55 a vertical multiburst a horizontal multiburstrst rectangle solid in odd, second solid in even ?ld vertical lines a moving cursor test pattern figure 3: digital video input port timing relationships in hd mode clk y_bus uv_bus dv_valid y0 u0 y1 y2 y3 y4 u1 v0 v1 u2 y5 v2 channel b channel a
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-5 to capture a picture using the build-in test pattern generator (odd and even ?ld), set up the registers as shown in t ab le 2 to start capturing at the upper left corner of the white frame. 2.4 input formats the vip accepts the following external video input streams: 8/10-bit data with encoded [eav/sav] syncs yuv 4:2:2 (alias d1 mode) 8-bit data with external [href, vref] syncs yuv 4:2:2 (alias vmi mode) 8/10-bit or 16/20-bit raw data samples (alias raw mode) 16/20-bit video data on 2 groups of pins for y and multiplexed u/v with both encoded [sav/eav] and explicit [hrefhd, vrefhd, frefhd] syncs (alias dual_stream or hd mode) the yuv 4:2:2 sampling scheme assumed by all modes is de?ed by ccir 601. d1 mode the d1 mode expects an 8/10-bit 4:2:2 video data stream (de?ed by ccir 656) with syncs encoded in the video data stream. 1 timing reference codes recognized are 80h, 9dh, abh, b6h, c7h, dah, ech and f1h. single bit errors in the reference codes are corrected, but double bit errors are rejected. the supported mode is shown in figure 5 . figure 4: test pattern table 2: test pattern generator setup mode reference window start (x,y) window end (x,y) ntsc href- / vref+ 8a,0 (138,0) 359,f1 (857,241) pal href- / vref+ 90,0 (144,0) 35f,11f (863,287) 1. for compatibility with 8-bit d1 interfaces the two lsbs are not used for timing reference extraction (as defined in ccir 656- 2).
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-6 this is strictly a single-stream mode, where vip captures on channel a (dv_data[9:0]) either 10-bit or 8-bit (msb aligned, with dv_data[1:0] unused) multiplexed yuv video data with embedded syncs. the dual_stream register should be programmed to 0 in this mode. vmi mode the vmi mode is an 8-bit yuv (4:2:2) mode with external horizontal and vertical reference signals, which follows the vmi protocol. chrominance and luminance input samples are multiplexed into a single 8-bit input data stream on channel a. the field identi?r (fid) is derived from the horizontal and vertical sync timing relation. this is also a single-stream mode, where vip captures on channel a (dv_data[9:0]) 8-bit vmi data with explicit syncs, where dv_data[9:2] correspond to vmi data and dv_data[1:0] correspond to vref and href respectively. the dual_stream register should be programmed to 0 in this mode. raw mode in raw mode, valid 8-bit or 10-bit data are continuously captured and written into system memory. both single and dual streams are supported in this mode. the dual_stream register can, therefore, be programmed to either 1 or 0 in this mode. in the single stream mode (dual_stream register = 0), 8-bit data (dv_data[9:2]) is captured as it is but 10-bit data (dv_data[9:0]) is extended to 16 bits by either adding leading zeros or by sign-extension. in the dual stream mode (dual_stream register = 1), only 8 msbs of the 10-bit data are valid for each of the 2 channels: a and b. two 8-bit data, dv_data[9:2] and dv_d_data[9:2], are captured simultaneously from the 8 upper bits of both the channels, for both 8-bit or 10-bit modes, and packed into one 16-bit entity. channel a and channel b data occupy the 8 lsbs and 8 msbs respectively, of the packed 16-bit result. raw mode is only available in the auxiliary capture path of the vip. it can be enabled independent of d1 or vmi mode. remark: raw mode may not be supported in next pnx15xx series generations. hd mode this is strictly a dual_stream mode (dual_stream register = 1), where vip expects 10-bit y and 10-bit u/v data on 2 separate inputs (channels a and b); the u/ v data is time multiplexed. in order to support a number of external decoders, this mode has been implemented to work not only with embedded or encoded syncs where eav and sav codes are embedded in the data, but also with explicit syncs where the synchronization reference is provided explicitly via href, vref, and fref figure 5: d1 data stream channel a u xy ff 00 00 v y y u y eav/sav
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-7 signals (as speci?d in the implementation of the tda8751 decoder from philips and the hmp8117 decoder from intersil). in hd mode href, vref, and fref are respectively connected to the vip module pins hrefhd, vrefhd an frefhd. the supported mode is shown in figure 6 . note that for detecting the embedded sync in this hd mode, the code is expected to be in the u/v stream; to this end, the current design checks only one of the streams, the u/v stream, for the presence of the embedded codes, assuming that any information embedded in the y stream is identical (see itu bt 1120, smpte 274m standards). the dual_stream register must be programmed to 1 in this mode. remark: the explicit sync signals are used only in the hd or dual_stream mode. t ab le 3 tries to capture the above discussion into a quick checklist of implemented input formats, where an x designates the presence (support) of the corresponding feature. figure 6: hd dual data stream channel b channel a y xy ff 00 00 y y y y y u xy ff 00 00 u v v u v identical eav/sav table 3: video input formats video modes single stream (yuv) dual stream (y and u/v) embedded sync explicit sync no sync embedded sync explicit sync no sync d1 8-bit x 10-bit x vmi 8-bit x 10-bit raw 8-bit x x 10-bit x x hd 8-bit x x 10-bit x x
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-8 2.5 video data path the relation between the video input formats and the supported data stream is shown in t ab le 4 . 2.5.1 video data flow the video datapath data?w for the vip is shown in figure 7 . 2.5.2 video data acquisition the video and auxiliary data extract block, shown in figure 1 , receives a continuous pixel stream from the video timing control block and outputs active window data and synchronization signals. bit ?lds in the windowing registers specify the start and end of the source windows relative to the reference edges of h and v syncs and size of the target windows. table 4: relationship between input formats and video data capture input modes single stream (yuv) video data dual stream (y and u/v) video data d1 8-bit x 10-bit x vmi 8-bit x hd 8-bit x 10-bit x figure 7: video data flow down_sample chroma u or uv or g v or b y or r (8) (8) (8) video timing control and video extraction dither up_sample horizontal filtering or color space conversion (10->9) (10->8) (9->8) or rounding -ordered dither chroma uyvy(8) uyvy(8/10) or uv(8/10) y(8/10) uv (8/10) y (8/10) uv (8) y (8) y u v (8) (8) (8) y or r (8) u or g v or b (8) (8) test pattern generator video input dither propagation (8->3,4,5,6) (64) (64) (64) (8) (8) (8) ( 8/5/4) (8/6/5/4) (8/5/4/3) y or r u or uv or g v or b pixel packing see table 10. dma1 dma2 dma3 -error
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-9 2.5.3 internal timing window start is de?ed relative to either the rising or falling edges of the vref and href inputs (or similar d1 events), as shown in figure 8 . the ?st quali?d data aligned with the rehs reference edge is interpreted as a u sample. if the uyvy data stream is out of sync, it can be realigned with the vsra bits in register 00100. for an example showing how to setup the windower and scaler to capture the entire test pattern, refer to t ab le 2 , figure 8 , and figure 9 . 2.5.4 field identi?r generation the field identi?r in the d1 mode is extracted from the f bit in every valid video header, whereas in the vmi mode, the same is derived from the value of the href signal during the negative edge of the vref signal. the field identi?r timing is illustrated in figure 10 , and t ab le 5 shows various field identi?d generation modes. note that instead of using the field identi?r derived from the video stream, it can also be forced to zero or forced to toggle after each new incoming ?ld; the forced figure 8: source and target window parameters figure 9: acquisition window counter reference hblank yws xws active source window target window line_size line_count xwe ywe vblank ff 00 00 80 u y v y sav 0 1 1 1 ff 00 00 9d eav u y v y 718 1 719 1 857 0 856 0 720 1 721 1 vip pixel & line ff 00 00 9d eav u y v y 721 0 720 526 720 526 ... ... 2 1 v bit h bit
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-10 value takes effect after the selected vertical reference edge occurs at the input. the sf bit controls how the field identi?r value is interpreted. any change of the field identi?r interpretation takes effect immediately. video acquisition window the start location of the window to be captured, relative to the input stream, is speci?d in the window start registers, 00140 ( vid_xws, vid_yws ). the stop location of the window to be captured, relative to the input stream, is speci?d in the window end register, 00144 ( vid_xwe, vid_ywe ). additional target window cropping, which might be necessary after scaling, can be done with the line_size and line_count values in the target window size register, 00304. dithering of the video data there are two identical dither units, pre-dither and post-dither, capable of 10->9, 10- >8 and 9->8 dithering/rounding with saturating values. these two dither units are cascaded together on the video data path. the two dither units are independent of each other, and controlled with separate mmio registers. input samples are assumed to be left (msb) aligned on the 10 bit input bus. output samples are left aligned (msb) on the 10 bit output bus. both dither units need to be disabled for an 8-bit input data stream, to avoid unexpected results. figure 10: field identi?r timing fid vmi href vref fid zero start of video window falling edge of vref start of video window falling edge of vref fid tgl change of ftgl & fzero bits vid _ yws vid _ xws table 5: field identi?r generation modes vdi8 href vsel fzero ftgl change at fid fid fswp meaning x f vmi 0 0 negedge vref !f 0 0 odd f x d1 0 0 valid d1 header f 1 0 even x x x 1 0 immediately 0 0 1 even x x x x 1 immediately * 0,1,0,.. 1 1 odd * fid toggles after detection of video window start.
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-11 the dither units can be used when the bit precision of samples needs to be limited, while preventing quantization effects in areas with almost uniform levels of shades in a picture. the following discussion refers to a single dither unit, either pre- or post-dither the dither unit processes up to 10 bit inputs. it receives all the three components, y, u and v, on two 10 bit input buses, and dithers/rounds them down to 8 or 9 bits. dithering can be enabled separately for luma (y) and chroma (u and v) components. if the dither unit is enabled but dithering is disabled, rounding, instead of dithering, is performed. whenever dithering is enabled, the dithering process alternates its activity between adjacent pixels: either every pixel or every two pixels. furthermore, any combination of three alternation patterns can be selected: line, ?ld, and frame alternations. the dither units are controlled by qvi_pre_dither_ctrl and qvi_post_dither_ctrl mmio registers, for the pre- and post-dither units, respectively. immediately after the unit is enabled, it waits for the beginning of the following captured image before it actually starts to operate. enabling the dither unit resets its internal state. dither mechanism the operation mode is programmable via mode in the dither-unit control register. the three available modes are: 10-bit input down to 8 bits of output 10-bit input down to 9 bits of output 9 bit input down to 8 bits of output. remark: 8-bit input samples are not changed when passed through the dither unit (the 8 output msbs are identical to the 8 input msbs, but the 2 output lsbs are changed by the dither unit). the dither unit independently dithers all the three components y, u, and v in the same way. each input pixel is processed independently in the sense that the value of the other inputs do not affect the processing of the current input. the unit is enabled with dither_enable. the programmer can select which components are dithered; with dither_y for the luma components, and dither_uv, independent of y, for the chroma components. when the dither unit is enabled, a component that is not selected for dithering goes through rounding. the ?al value of all components is saturated at 1023, which is the largest value represented by the 10 bit output. whenever the dithering operation is enabled, the process of dithering alternates between successive pixel-components, either every pixel or every two pixels, in the same image line. this option is programmable with double_pixel_alt for single or double pixel alternation. there are another three dithering options that can be enabled or disabled independently: alternate processing between successive lines, ?lds and frames.
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-12 enabling the dither units immediately after the dither unit is enabled or after a reset, the unit waits for the beginning of a newly-captured image. only then the unit starts dithering. once the dither unit is operational (enabled), it keeps track of the order in which the images arrive: we refer to the very ?st image at the unit dither as the even image, the second image as the odd image, and so on. a frame here is de?ed as two images: an even image followed by an odd image. this maintained state does not depend on the selected alternation options, it is maintained as long as the dither unit is enabled. any alternative activity corresponds to the internally-maintained state of a frame and ?ld (even or odd) and has nothing to do if the signal is coming from the top or the bottom ?ld. dithering operation also distinguishes between even and odd pixel-components of the same type (either y, u or v) in a line. the ?st occurrence of a y or u or v component in the ?st line in the ?st received image is considered to be an even occurrence (or set ). 2.5.5 horizontal video filters (sampling, scaling, color space conversion) interpolation filter (upsampling) all horizontal video processing is based on equidistant sampled components. all 4:2:2 video streams, therefore, have to be upsampled before being scaled horizontally. the interpolation fir ?ter used can interpolate interspersed or co-sited chroma samples. mirroring of samples at the ?ld boundaries compensate for run-in and run-out conditions of the ?ter. the following coef?ients are used: co-sited: a=(1) and b=(-3,19,19,-3)/32 interspersed: c=(-1,5,13,-1)/16 and d=(-1,13,5,-1)/16 decimation filter (downsampling) after horizontal processing, the chrominance may be down-sampled to reduce memory bandwidth or allow a higher-quality vertical processing not available otherwise. mirroring of samples at the ?ld boundaries compensate for run in and run out conditions of the ?ter. the following coef?ients are used: co-sited: low pass a=(1,2,1)/4 or sub-sample a=(0,1,0) interspersed: b=(-3,19,19,-3)/32 normal polyphase filter (horizontal scaling) the normal polyphase ?ter can be used to zoom up (upscale) or downscale a video image. depending on the number of components, the ?ter is used with 6 taps (three- component mode) or 3 taps (four-component mode).
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-13 color space matrix mode in addition to normal and transposed polyphase ?tering (scaling), the fir ?ter structure can instead be programed to perform color space-conversion. a dedicated set of registers holds the coef?ients for the color-space matrix. horizontal scaling and color space conversion are mutually exclusive. 2.5.6 video data write to memory the vip can produce a variety of output formats. video formats range from a single- component up to three-component formats (like a 4:4:4 yuv). up to three write planes can be de?ed. on the input, the video format is restricted to yuv 4:2:2 as de?ed in itu-r-656 or 8/10 raw data. on the output, true color and compressed formats are supported. for a complete list of supported video formats, refer to section 3. register descr iptions . the pixel packing unit takes care of quantization and packing of the color components into 64-bit units. a list of the most common video formats supported is shown in t ab le 6 . packing of a pixel into 64-bit units is always done from right to left while bytes within one pixel unit are ordered according to the endian mode settings (speci?d by the global endian mode register; endian mode bit in the output format register can, however, invert that signal). t ab le 6 shows the location of the ?st ?ixel unit within a 64-bit word in the little endian mode. the selected endian mode will affect the position of the components within a multi-byte pixel unit! remark: vip does not explicitly support a 4:2:0 memory format. such a format can be obtained by discarding partial data written to memory. table 6: output pixel formats format 3 1 3 0 2 9 2 8 2 7 2 6 2 5 2 4 2 3 2 2 2 1 2 0 1 9 1 8 1 7 1 6 1 5 1 4 1 3 1 2 1 1 1 0 9 8 7 6 5 4 3 2 1 0 planar yuv (4:4:4, 4:2:2) or rgb plane #1 plane #2 plane #3 y8 or r8 u8 or g8 v8 or b8 semi planar yuv (4:2:2) plane #1 plane #2 y8 or r8 u8/v8 packed 4/4/4 rgba alpha r4 g4 b4 packed 4/5/3 rgba alpha r4 g5 b3 packed 5/6/5 rgb r5 g6 b5 packed yuy2 4:2:2 u8 or v8 y8 packed uyvy 4:2:2 y8 u8 or v8 packed 888 rgb(a) (alpha) r8 or y8 g8 or u8 b8 or v8 packed 4:4:4 vyu(a) (alpha) v8 y8 u8
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-14 capture enable mode using the cfen bits, video capture can be limited to odd or even or both ?lds. if both ?lds are to be captured, the capture starts with the next odd ?ld. the status of the osm (one-shot) bit in the mode-control-register speci?s the capture mode (one-shot or continuous): if osm =0, the corresponding incoming video stream is captured continuously. for example, in a video conference application the vanity image would be a continuous stream to the frame buffer. if osm =1, the corresponding incoming video stream is captured one ?ld or frame at a time (depending on the cfen bits). programming hint: in a video conference application the captured image would be a one-shot stream to the host memory. if you write osm =1 and select ?ld/frame in the register, it is captured on the next vsync and cfen bits are cleared to 0. to capture the next image, the cfen and osm bits must be reprogrammed. address generation the line address is generated by loading the base address from the corresponding register set at the beginning of each ?ld and adding the line pitch to it at the beginning of every new line.the lower three bits of the ?st three base address registers are used as an intra-long-word offset for the left-most pixel components of each line. the offset has to be a multiple of the number of bytes per component. double buffer mode to avoid line tear caused by trying to display a frame at the same time that it is being updated, a double buffer mode is available. in this double buffer mode, a second set of dma base addresses is available. after capturing and storing one complete frame in the location described by one set, the other set is used for the next frame. the idea is illustrated in figure 11 . figure 11: double buffer mode frame 1 frame 2 dma_base1 dma_base2 odd even odd even dma_base3 dma_base4
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-15 2.5.7 auxiliary data path the relationship between the input data modes and the supported auxiliary capture modes is shown in t ab le 7 . auxiliary data flow the auxiliary data ?w is shown in figure 12 . table 7: relationship between input formats and data capture input modes single-stream auxiliary data dual-stream auxiliary data aux anc raw aux anc raw d1 8-bit x x 10-bit x x vmi 8-bit x x raw 8-bit x x 10-bit x x hd 8-bit x 10-bit x figure 12: auxiliary data flow video timing control and aux data uyvy(8) uyvy(8/10) or uv(8/10) y(8/10) test pattern generator video input extraction (16) (64) dma3 pixel packing single-stream: uyuy(8) uyuv(10) and aux_bps==0 uyuv(10) and aux_bps==1 dual-stream y(8) uv(8) y(10) uv(10) 0 or sign
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-16 auxiliary data acquisition capturing auxiliary data utilizes the same dma engine used for the third video plane. capture of overlapping video and auxiliary regions is, therefore, only possible when semi-planar or packed formats are being used. data can be captured in either 8- or 10-bit modes. in the single-stream mode, 10-bit data is extended to 16 bits by either adding leading zeros or by sign-extension. in dual stream mode, only 8 msbs of a 10- bit data are valid; two such msb sets (2x8-bit data) are captured simultaneously, for either 8-bit or 10-bit modes, and packed to form a resultant 16-bit unit. thus, channel a data (8 bits) and channel b data (8 bits) are located at the 8 lsbs and the 8 msbs respectively, of the packed 16-bit data. three different types of auxiliary data capture are de?ed: ancillary data capture (anc) auxiliary data acquisition window (aux) raw data capture (raw) a buffer-size register can be used to limit data acquisition by size (one shot mode) or de?e a ring-buffer length. even though anc and aux capture can be enabled separately, simultaneous capture of anc and aux is not advisable. timing and sequence of anc and aux data are not necessarily related and therefore are likely to lead to unpredictable results if simultaneous capture is attempted! ancillary data capture ancillary data, embedded in the stream and marked by itu-r-1364 header codes, can be decoded and extracted for software processing (see figure 13 ). aux_bps register speci?s the number of bits to be captured per anc sample. in the 8-bit mode, two lsbs of the 10-bit data bus are ignored. ancillary data capture is not supported in the dual stream mode. figure 13: anc data structure dbn* 00 00 + ff + ff + did dc cs data data data data data data data anc preamble user data words (max.255) + 8 msb of input data checked dbn* dc cs size of 8-bit user data words = dc[7:2] x 4 size of 10-bit user data words = dc[7:0] ancillary data packet: captured data: data bit allocation: 3 4 1 2 0 8 9 6 7 5 8-bit data range 10-bit data range msb lsb did * dbn for type 1 or sdid for type 2 (itu-r-1364)
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-17 four sequential anc preamble bytes, 00, ff, ff and a quali?d did word, enable anc data capture. a quali?d did word is de?ed: masked aux_anc-enabled id matched (see figure 13 ) bit 8 is even parity for bit 7-0(10-bit data mode) / bit 7-2(8-bit data mode) bit 9 = not bit 8 2 lsbs of both id_mask_0 and id_mask_1 need to be programmed to 2?00 in 8- bit data mode to prevent unexpected results. in the type 1 case, the data block number (dbn) distinguishes successive data packets with a common data id. in the type 2 case, the did is followed by the secondary identi?ation (sdid). the captured packed length is taken form the data count (dc) byte. a value of dc=0 will capture exactly four data words consisting of did, dbn (or sdid), dc and checksum (cs). if dc is not equal to 0, additional user data words de?ed by dc are captured. parity bits for dbn (or sdid) and dc bytes are not checked. auxiliary data acquisition window the auxiliary data acquisition window can be used to capture either vbi data or an additional region of video data. it provides yet another capture-window. the ?ld identi?r is compared against aux_cfen bits at the start of the programmed window to control whether a ?ld is captured or not. the start and end points of the auxiliary window are de?ed by the aux window start and end registers at offsets 00180 and 00184 ( aux_xws, aux_yws, aux_xwe, aux_ywe ). the aux_xws parameter speci?s the number of the ?st pixel to be captured after the href reference edge.the aux_yws parameter speci?s the number of the ?st line to be captured after aux reference edge. the aux_xwe parameter speci?s the number of the last pixel to be captured.the aux_ywe parameter speci?s the number of the last line to be captured. pixel and lines start counting at 0. figure 14: anc masked id checking data stream did word 3 4 1 2 0 8 9 6 7 5 msb lsb 3 4 1 2 0 6 7 5 3 4 1 2 0 6 7 5 id of 10-bit data id of 8-bit data id_mask_0/id_mask_1 data_id_0/data_id_1 id_mask_*[i] bit enables data_id_*[i] bit checking on bit i of a data stream did word
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-18 raw data capture raw data capture overrides anc or aux data capture modes when enabled. in this raw capture mode, any validated data at the video port is captured regardless of external or embedded synchronization signals. aux data write to memory auxiliary data capture formats, for writing into the frame buffer, are limited to raw luma and chroma samples in 8 or 10 bit formats (extended to 16 bit). optionally, writing of chroma samples can be omitted. capture enable mode the aux_cfen bits specify the ?lds from which the device is to capture the aux data. if cfen=0, no auxiliary data is captured. once the capture of an auxiliary window has started, resetting these bits has no effect until the end of the video window. the aux_anc bits specify the type of ancillary data blocks to be fetched. once the capture of an anc block has started, resetting of these bits has no effect until the end of the data block. the aux_raw bit enables continuous capturing of raw samples regardless of external or internal syncs. if raw capture is enabled, aux_cfen and aux_anc bit settings are ignored. the aux_bsize value speci?s, in number of bytes, the size of the buffer available for aux data. the aux_pitch bits specify the aux line pitch, i.e. , the difference in the address from a pixel on a line to the same pixel on the next line, when pitch mode is enabled. pitch mode is also de?ed for the anc data capture, where each packet is treated as a new video line. the aux_osm bit can be used to automatically limit capture by stopping after any wrap condition is reached. end of aux window wrap condition also applies to anc capture, even if aux capture is disabled. the data buffered in the local fifos is ?shed when a wrap condition is reached or in pitch mode at the end of each video line or anc packed. for the raw mode, the data is also ?shed when disabling raw capture. address generation the aux dma base address register provides 28 bits to specify a destination address for storing the aux data in the frame buffer. the address generation is similar to that of video capture, except for the missing double-buffer and ?ld modes. the relationship between the input data formats and the different video and auxiliary data capture scenarios is shown in t ab le 8 . it is important to note, however, that the current vip design does not support mixing of aux and anc data.
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-19 2.5.8 interrupt generation the vip contains a dvp-compliant interrupt generation mechanism. interrupts can be generated for the following events: start of video end of video (written to memory) start of aux in end of aux out (written to memory) line threshold pipeline error (due to illegal scaling ratio e.g. >2x scaling or memory bus bandwidth error (?o over?w)) in addition to these interrupts, the vip module also provides last-pixel-in signals, for the vbi and video capture modes, to the gpio block for timestamping. 3. register descriptions 3.1 register summary the base address for vip mmio registers begins at absolute offset (with respect to mmio_base) of 0x10 6000. table 8: relationship between input formats and data capture video modes single stream (yuv) dual stream (y and u/v) video data auxiliary data video data auxiliary data aux anc raw aux anc raw d1 8-bit x x x 10-bit x x x vmi 8-bit x x x x raw 8-bit x x 10-bit x x hd 8-bit x x 10-bit x x table 9: vip mmio register summary offset name description 0x10 6000 vip_mode vip operation mode 0x10 6020 anc_did_even anc did for even ?ld 0x10 6024 anc_did_odd anc did for odd ?ld 0x10 6040 vip_linethr video line count threshold 0x10 6100 vin_format video input format and mode
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-20 0x10 6104 vin_testpgen video test pattern generator 0x10 6140 win_xystart video horizontal and vertical acquisition window start 0x10 6144 win_xyend video horizontal and vertical acquisition window end 0x10 6160 pre_dit_ctrl pre-dither control 0x10 6164 post_dit_ctrl post_dither control 0x10 6180 aux_xystart auxiliary horizontal and vertical acquisition window start 0x10 6184 aux_xyend auxiliary horizontal and vertical acquisition window stop 0x10 6200 hsp_zoom_0 initial zoom for 1st pixel in line (unsigned) 0x10 6204 hsp_phase horizontal phase control 0x10 6208 hsp_dzoom_0 initial zoom delta for 1 pixel in line (signed) 0x10 620c hsp_ddzoom zoom delta change (signed) 0x10 6220 csm_coeff0 color space matrix coef?ients c 00 - c 02 0x10 6224 csm_coeff1 color space matrix coef?ients c 10 - c 12 0x10 6228 csm_coeff2 color space matrix coef?ients c 20 - c 22 0x10 622c csm_offs1 color space matrix offset coef?ients d 0 -d 2 0x10 6230 csm_offs2 color space matrix rounding coef?ients e 0 -e 2 0x10 6284 csm_ckey color key components 0x10 6300 psu_format output format and mode 0x10 6304 psu_window target window size 0x10 6340 psu_base1 target base address dma #1 0x10 6344 psu_pitch1 target line pitch component 1 0x10 6348 psu_base2 target base address dma #2 0x10 634c psu_pitch2 target line pitch component 2 and 3 0x10 6350 psu_base3 target base address dma #3 0x10 6354 psu_base4 target base address dma #4 0x10 6358 psu_base5 target base address dma #5 0x10 635c psu_base6 target base address dma #6 0x10 6380 aux_format auxiliary capture output format and mode 0x10 6390 aux_base auxiliary capture base address 0x10 6394 aux_pitch auxiliary capture line pitch 0x10 6800 69fc coeff_table coef?ient table for horizontal ?ter (0-5) 0x10 6fe0 int_status interrupt status register 0x10 6fe4 int_enable interrupt enable register 0x10 6fe8 int_clear interrupt clear register 0x10 6fec int_set interrupt set register 0x10 6ffc module_id module identi?ation and revision information table 9: vip mmio register summary ?ontinued offset name description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-21 3.2 register table table 10: video input processor (vip) 1 registers bit symbol acces s value description operating mode control registers offset 0x10 6000 vip mode control 31:30 vid_cfen[1:0] r/w 0 video window capture ?ld enable 00 = capture disabled 01 = capture odd only 10 = capture even only 11 = capture both 29 vid_osm r/w 0 video capture one shot mode 0 = continuously capture ?lds selected by cfen 1 = capture ?lds selected by cfen only once 28 vid_fseq r/w 0 video capture ?ld sequence 0 = capture ?lds starting with any ?ld 1 = capture ?lds starting with odd ?ld setting has no effect unless vid_cfen is set to capture both 27:26 aux_cfen[1:0] r/w 0 auxiliary window capture enable 00 = capture disabled 01 = capture odd only 10 = capture even only 11 = capture both 25 aux_osm r/w 0 auxiliary capture one shot mode 0 = when auxiliary wrap event is reached, buffer wraps around 1 = when auxiliary wrap event is reached, capturing stops 24 aux_fseq r/w 0 auxiliary capture ?ld sequence 0 = capture ?lds starting with any ?ld 1 = capture ?lds starting with odd ?ld setting has no effect unless aux_cfen is set to capture both 23:22 aux_anc[1:0] r/w 0 anc data capture enable 00 = no anc data captured 01 = odd anc ?ld blocks. (masked data_id_0 bit matched) 10 = even anc ?ld blocks. (masked data_id_1 bit matched) 11 = odd/even anc ?ld blocks. (masked data_id_* bit matched) 21 aux_raw r/w 0 auxiliary raw capture enable 0 = raw capture disabled 1 = raw capture enabled, all samples will be captured when enabled, aux_anc and aux_cfen settings are ignored 20:18 reserved 17 rst_on_err r/w 0 reset on error writing a one into this bit will automatically reset the block in case of a pipeline error (e.g. illegal scaling ratio / fifo over?w) 16 soft_reset w 0 soft reset writing a one into this bit will reset the block 15 reserved
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-22 14 iff_clamp r/w 0 clamp mode for iff (affects u/v only) 0: clamp to 0-255 1: clamp to 16 - 240 (ccir range) 13:12 iff_mode r/w 0 interpolation mode 00: bypass 01: reserved 10: co-sited 11: interspersed 11 reserved 10 dff_clamp r/w 0 clamp mode for dff (affects u/v only) 0: clamp to 0-255 1: clamp to 16 - 240 (ccir range) 9: 8 dff_mode r/w 0 decimation mode 00: bypass 01: co-sited (sub sample) 10: co-sited (low pass) 11: interspersed 7:4 reserved 3 hsp_clamp r/w 0 clamp mode for hsp 0: clamp to 0-255 1: clamp to ccir range de?ed by bit 2 2 hsp_rgb r/w 0 color space mode, de?es ccir clamping range for hsp 0: processing in yuv color space 1: processing in rgb color space 1:0 hsp_mode r/w 0 horizontal processing mode 00: bypass mode 01: color space matrix mode 10: normal polyphase mode 11: transposed polyphase mode anc identi?r codes (did) offset 0x10 6020 anc identi?r codes - odd field 31:16 reserved 15:8 id_mask_0[7:0] r/w 0xfc mask for enabling bit checking on anc identi?r code for each id_mask_0[i] bit, 1: enable data_id_0[i] bit checking 0: disable data_id_0[i] bit checking 7:0 data_id_0[7:0] r/w 0x44 anc identi?r code offset 0x10 6024 anc identi?r codes - even field 31:16 reserved 15:8 id_mask_1[7:0] r/w 0xfc mask for enabling bit checking on anc identi?r code for each id_mask_1[i] bit, 1: enable data_id_1[i] bit checking 0: disable data_id_1[i] bit checking 7:0 data_id_1[7:0] r/w 0x54 anc identi?r code table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-23 video informations registers offset 0x10 6040 vip line threshold 31:11 reserved 10:0 lcthr[10:0] r/w 0 video line count threshold line threshold status bit is set if video line count (svlc) reaches this value note: it is possible to have multiple interrupts per ?ld at different line counts, by re-programming the threshold value in this register from the isr. input format control registers offset 0x10 6100 video input format 31:30 vsra[1:0] r/w 0 video stream realignment 00 = normal 01 = ignore 1st sample after href 1x = reserved 29:26 reserved - 25 synchd r/w 0 hd sync select 0 = embedded sync 1 = explicit sync 24 dual_stream r/w 0 dual video data stream enable 0 = single video data stream mode 1 = dual video data stream mode 23:21 reserved - 20 nhdaux r/w 0 header detect during aux window 0 = d1 header detection enabled inside aux window 1 = d1 header detection disabled inside aux window 19 npar r/w 0 parity check disable 0 = parity check enabled for d1 header detection 1 = parity check disabled for d1 header detection 18:16 reserved - 15:14 vsel[1:0] r/w 0 video source select 00 = reserved 01 = video port, encoded sync (d1-mode) 10 = video port, external sync (vmi-mode) 11 = reserved 13 twos r/w 0 uv data type 0 = offset binary 1 = twos complement 12 tpg r/w 0 test pattern generator 0 = video stream selected by vsel 1 = internal test pattern generator 11:10 reserved - 10 fref r/w 0 field toggle reference mode 0 = normal, use vref 1 = toggling field bit is used as vertical reference table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-24 9 ftgl r/w 0 field toggle mode 0 = normal 1 = free toggle (sequence starts with fid = 0) 8:4 reserved - 3 sf r/w 0 swap ?ld interpretation 0: odd (?st) ?ld = 0, even (second) ?ld = 1 1: odd (?st) ?ld = 1, even (second) ?ld = 0 2 fzero r/w 0 force fid value to zero 0 = ?ld identi?r derived from input stream 1 = force ?ld identi?r value to 0 1 revs r/w 0 vertical sync reference edge 0 = falling edge / start of active video 1 = rising edge / end of active video 0 rehs r/w 0 horizontal sync reference edge 0 = falling edge / sav 1 = rising edge / eav offset 0x10 6104 video test pattern generator control 31 pal r/w 0 field generation mode 0 = ntsc timing 1 = pal timing 30 reserved 0 29 vsel r/w 0 vertical timing signal select (will be removed) 0 = generate vref 1 = generate vs 28 hsel r/w 0 horizontal timing signal select (will be removed) 0 = generate href 1 = generate hs 27 swap r/w 0 alternative test pattern 0 = normal test pattern 1 = test pattern with diagonal patterns, etc. 26 move r/w 0 scrolling enable for alternative test pattern 0 = no scrolling 1 = scrolling enabled 25:0 reserved 0 video acquisition window control registers offset 0x10 6140 video acquisition window start 31:27 reserved - 26:16 vid_xws[10:0] r/w 0 horizontal video window start the pixel co-sited with the reference edge rehs is numbered 0. 15:11 reserved - 10:0 vid_yws[10:0] r/w 0 vertical video window start the ?st line indicated by the reference edge revs is numbered 0. offset 0x10 6144 video acquisition window end 31:27 reserved - table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-25 26:16 vid_xwe[10:0] r/w 0 horizontal video window end pixels from xws up to and including xwe are processed 15:11 reserved - 10:0 vid_ywe[10:0] r/w 0 vertical video window end lines from yws up to and including ywe are processed offset 0x10 6160 pre-dither control offset 0x10 6164 post-dither control 31 dither_enble r/w 0 dither control enable / disable the dither unit. dither_enable = 0 : disable; dither_enable = 1 : enable. 30 dither_y r/w - dither y components enable / disable dithering of y pixel-components. dither_y = 0 : disable (round and clip); dither_y = 1 : enable (dither). 29 dither_uv r/w - dither u and v components enable / disable dithering of u and v pixel-components. dither_uv = 0 : disable (round and clip); dither_uv = 1 : enable (dither). 28:27 mode[1:0] r/w - mode of operation select input and output sizes and the computations carried out: mode = 0 : 10->9; mode = 1 : 10->8; mode = 2 : 9->8; mode = 3: reserved. 26:4 reserved r - 3 frame_alt r/w - frame alternate enable/disable frame alternation while dithering. frame_alt = 0 : disable; frame_alt = 1 : enable. 2 field_alt r/w - field alternate enable/disable ?ld alternation while dithering. field_alt = 0 : disable; field_alt = 1 : enable. 1 line_alt r/w - line alternate enable/disable line alternation while dithering. line_alt = 0 : disable; line_alt = 1 : enable. 0 double_pixel_alt r/w - single or double pixel alternate select single or double pixel alternation while dithering. double_pixel_alt = 0 : single pixel alternation; double_pixel_alt = 1 : double pixel alternation. vbi acquisition window control registers offset 0x10 6180 auxiliary acquisition window start 31:27 reserved - 26:16 aux_xws[10:0] r/w 0 horizontal auxiliary window start the pixel cosited with the reference edge rehs is numbered 0. table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-26 15:11 reserved - 10:0 aux_yws[10:0] r/w 0 vertical auxiliary window start the line cosited with the reference edge revs is numbered 0. offset 0x10 6184 auxiliary acquisition window end 31:27 reserved - 26:16 aux_xwe[10:0] r/w 0 horizontal auxiliary window end pixels from xws up to and including xwe are processed 15:11 reserved - 10:0 aux_ywe[10:0] r/w 0 vertical auxiliary window end lines from yws up to and including ywe are processed horizontal video processing control registers offset 0x10 6200 initial zoom 31:29 hsp_phase_mode[2: 0] r/w 0 phase mode 0: 64 phases 1: 32 phases 2: 16 phases 3: 8 phases 4: 4 phases 5: 2 phases 6: ?ed phase 7: linear phase interpolation (only valid for4 component mode) 28:27 reserved - 26 hsp_fir_comp[1:0] r/w horizontal ?ter components 0: three components, 6 tap fir each 1: four components, 3 tap fir each (4th component unused) in color space matrix mode this value has to remain zero 25:20 reserved - 19: 0 hsp_zoom_0[19:0] r/w 0 initial zoom for 1st pixel in line (unsigned, lsb = 2 -16 ) 2 0000 (hex): downscale 50% 1 0000 (hex): no scaling = 2 0 0 8000 (hex): zoom 2 x (transposed: downscale 50%) offset 0x10 6204 phase control 31 reserved - 30:28 hsp_qshift[2:0] r/w 0 quantization shift control used to change quantization before being multiplied with hsp_multiply. 100 (bin): divide by 16 101 (bin): divide by 8 110 (bin): divide by 4 111 (bin): divide by 2 000 (bin): multiply by 1 001 (bin): multiply by 2 010 (bin): multiply by 4 011 (bin): multiply by 8 warning: a value range over?w caused by an improper quantization shift can not be compensated later by multiplying with a hsp_multiply value below 0.5! table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-27 27:26 reserved - 25 hsp_qsign r/w 0 quantization sign bit 24:16 hsp_qmultiply[8:0] r/w 0 quantization multiply control used to compensate for different weight sum in transposed polyphase or color space matrix mode, remaining bits are fraction (largest number is 511/512) value range: . instead of using values in the range of the quantization shift hsp_qshift should be modi?d to gain more precision in the truncated result. 15:13 reserved - 12: 0 hsp_offset_0 r/w 0 initial start offset for dto offset 0x10 6208 initial zoom delta 31:26 reserved - 25: 0 hsp_dzoom_0[25:0] r/w 0 initial zoom delta for 1 pixel in line (signed, lsb = 2 -27 ) used for non constant scaling ratios offset 0x10 620c zoom delta change 31:29 reserved - 28: 0 hsp_ddzoom[28:0] r/w 0 zoom delta change (signed, lsb = 2 -40 ) used for non constant scaling ratios color space matrix registers offset 0x10 6220 color space matrix coef?ients c 00 - c 02 31:30 unused - 29:20 csm_c02[9:0] r/w 0 coef?ient c02, twos complement 19:10 csm_c01[9:0] r/w 0 coef?ient c01, twos complement 9:0 csm_c00[9:0] r/w 0 coef?ient c00, twos complement offset 0x10 6224 color space matrix coef?ients c 10 - c 12 31:30 unused - 29:20 csm_c12[9:0] r/w 0 coef?ient c12, twos complement 19:10 csm_c11[9:0] r/w 0 coef?ient c11, twos complement 9:0 csm_c10[9:0] r/w 0 coef?ient c10, twos complement offset 0x10 6228 color space matrix coef?ients c 20 - c 22 31:30 unused - 29:20 csm_c22[9:0] r/w 0 coef?ient c22, twos complement 19:10 csm_c21[9:0] r/w 0 coef?ient c21, twos complement 9:0 csm_c20[9:0] r/w 0 coef?ient c20, twos complement offset 0x10 622c color space matrix offset coef?ients d 0 - d 2 31:29 unused - 28 csm_d2_twos r/w 0 offset coef?ient d 2 type 0 = unsigned 1 = signed 27:20 csm_d2[7:0] r/w 0 offset coef?ient d 2 table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description 0 m 1.0 < m 0.5 <
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-28 19 unused - 18 csm_d1_twos r/w 0 offset coef?ient d 1 type 0 = unsigned 1 = signed 17:10 csm_d1[7:0] r/w 0 offset coef?ient d 1 9 unused - 8 csm_d0_twos r/w 0 offset coef?ient d 0 type 0 = unsigned 1 = signed 7:0 csm_d0[7:0] r/w 0 offset coef?ient d 0 offset 0x10 6230 color space matrix offset coef?ients e 0 - e 2 31:30 unused - 29:20 csm_e2[9:0] r/w 0 offset coef?ient e2, twos complement 19:10 csm_e1[9:0] r/w 0 offset coef?ient e1, twos complement 9:0 csm_e0[9:0] r/w 0 offset coef?ient e0, twos complement color keying control registers offset 0x10 6284 color key components 31: 24 ckey_alpha r/w 0 alpha value de?es the alpha value to be used for keyed samples. 23: 0 reserved video output format control registers offset 0x10 6300 video output format 31:30 psu_bamode r/w 0 base address mode 00 = single set (e.g. progressive video source) base 1-3 according to number of planes (plane 1-3) 01 = reserved 10 = alternate sets each ?ld (e.g. interlaced video source) base 1-3, odd ?ld (plane 1-3) base 4-6, even ?ld (plane 1-3) 11 = alternate sets each ?ld and frame (e.g. double buffer mode) packed modes only, frame index is set to 1 if cfen=0, frame index is incremented after capturing even ?ld before capturing odd, base address byte offset is de?ed in psu_offset1 base 1, odd ?ld 1st frame (plane 1 only) base 2, even ?ld 1st frame (plane 1 only) base 3, odd ?ld 2nd frame (plane 1 only) base 4, even ?ld 2nd frame (plane 1 only) 29:14 reserved - 13 psu_endian r/w 0 output format endianess 0: same as system endianess 1: opposite of system endianess 12 reserved - table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-29 11:10 psu_dither r/w 0 output format dither mode 00: no dithering 01: error dispersion (never reset pattern) 10: error dispersion (reset pattern at ?st capture enable) 11: error dispersion (reset pattern every ?ld) 9:8 psu_alpha r/w 0 output format alpha mode 00 = no alpha (alpha byte not written) 01 = alpha byte written, value from ckey_alpha (offset 284) 10 = reserved 11 = reserved setting 00 is ignored if size of alpha component is less than 8 bits 7:0 psu_opfmt r/w 0 output formats 08 (hex) = yuv 4:2:2, semi-planar 0b (hex) = yuv 4:2:2, planar 0f (hex) = rgb or yuv 4:4:4, planar a9 (hex) = compressed 4/4/4 + (4 bit alpha) aa (hex) = compressed 4/5/3 + (4 bit alpha) ad (hex) = compressed 5/6/5 a0 (hex) = packed yuy2 4:2:2 a1 (hex) = packed uyvy 4:2:2 e2 (hex) = yuv or rgb 4:4:4 + (8 bit alpha) e3 (hex) = vyu 4:4:4 + (8 bit alpha) offset 0x10 6304 target window size 31:27 reserved - 26:16 psu_lsize r/w 0 line size used for horizontal cropping after scaling 0 = cropping disabled 1 = one pixel 15:11 reserved - 10:0 psu_lcount r/w 0 line count used for vertical cropping after scaling 0 = cropping disabled 1 = one line video output address generation control registers offset 0x10 6340 target base address #1 31:28 reserved - 27: 3 psu_base1 r/w base address dma #1 used depending on psu_bamode setting 2:0 psu_offset1 r/w base address byte offset plane 1 bits de?e pixel offset within multi pixel 64 bit words (e.g. a 16bit pixel can be placed on any 16 bit boundary) offset 0x10 6344 target line pitch #1 31:15 unused - 14: 3 psu_pitch1 r/w line pitch dma #1, signed value (twos complement) used for all packed formats and for plane 1 2:0 unused - offset 0x10 6348 target base address #2 table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-30 31:28 unused - 27: 3 psu_base2 r/w base address dma #2 used depending on psu_bamode setting 2:0 psu_offset2 r/w base address byte offset plane 2 bits de?e pixel offset within multi pixel 64 bit words (e.g. a 16bit pixel can be placed on any 16 bit boundary) offset 0x10 634c target line pitch #2 31:15 unused - 14: 3 psu_pitch2 r/w line pitch dma #2, signed value (twos complement) used for planes 2 and 3 2:0 unused - offset 0x10 6350 target base address #3 31:28 unused - 27: 3 psu_base3 r/w base address dma #3 used depending on psu_bamode setting 2:0 psu_offset3 r/w base address byte offset plane 3 bits de?e pixel offset within multi pixel 64 bit words (e.g. a 16bit pixel can be placed on any 16 bit boundary) offset 0x10 6354 target base address #4 31:28 unused - 27: 3 psu_base4 r/w base address dma #4 used depending on psu_bamode setting 2: 0 unused - offset 0x10 6358 target base address #5 31:28 unused - 27: 3 psu_base5 r/w base address dma #5 used depending on psu_bamode setting 2: 0 unused - offset 0x10 635c target base address #6 31:28 unused - 27: 3 psu_base6 r/w base address dma #6 used depending on psu_bamode setting 2: 0 unused - auxiliary data output format control registers offset 0x10 6380 auxiliary capture output format 31:30 aux_bamode 0 base address mode 00 = pitch mode, wrap at end of buffer or window 01 = pitch mode, wrap at end of buffer 10 = append mode, wrap at end of buffer or window 11 = append mode, wrap at end of buffer 29:27 reserved - table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-31 26 aux_sgnex r/w 0 auxiliary capture sign extension 0 = no sign extension 1 = sign extension enabled for 10 bit samples 25 aux_bps r/w 0 auxiliary capture bits per sample 0 = 8 bit samples 1 = 10 bit samples 24 aux_subsample r/w 0 auxiliary capture sub-sample 0 = all samples 1 = luma (even) samples only not available for anc data capture 23:22 reserved - 21:0 aux_bzsize[21:0] r/w 0 auxiliary capture ringbuffer size size of ringbuffer in bytes, 0 = unlimited buffer size auxiliary data output address generation control registers offset 0x10 6390 auxiliary capture base address 31:28 unused - 27: 0 aux_base r/w 0 auxiliary capture base address lower 3 bits de?e byte offset within 64 bit words, offset has to be a multiple of the byte per unit size (e.g. a 16bit unit can be placed on any 16 bit boundary) offset 0x10 6394 auxiliary capture line pitch 31:15 unused - 14: 3 aux_pitch r/w 0 auxiliary capture line pitch signed value 2:0 unused - miscellaneous registers offset 0x10 6800 - 69fc coef?ient table #1 taps 0-5 (horizontal) 63:62 unused - 61:52 tap_5[x][9:0] w - inverted coef?ient, tap #5, twos complement 51:42 tap_4[x][9:0] w - inverted coef?ient, tap #4, twos complement 41:32 tap_3[x][9:0] w - inverted coef?ient, tap #3, twos complement 31:30 unused - 29:20 tap_2[x][9:0] w - inverted coef?ient, tap #2, twos complement 19:10 tap_1[x][9:0] w - inverted coef?ient, tap #1, twos complement 9:0 tap_0[x][9:0] w - inverted coef?ient, tap #0, twos complement interrupt and status control registers offset 0x10 6fe0 interrupt status 31 stat_fid_aux r 1 field identi?r at start of auxiliary window 30 stat_fid_vid r 0 field identi?r at start of video window 29 stat_fid_vpi r 0 field identi?r at video input port 28 unused - table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-32 27:16 stat_line_count [11:0] r 0 source video line count 15:10 unused - 9 stat_aux_ovrflw r 0 auxiliary buffer over?w event 8 stat_vid_ovrflw r 0 video buffer over?w event 7 stat_win_seqbrk r 0 windower sequence break event 6 stat_fid_seqbrk r 0 field identi?r sequence break event 5 stat_line_thresh r 0 line counter threshold reached event 4 stat_aux_wrap r 0 auxiliary capture write pointer wrap around event 3 stat_aux_start_in r 0 start of auxiliary data acquisition event 2 stat_aux_end_out r 0 end of auxiliary data write to memory event 1 stat_vid_start_in r 0 start of video data acquisition event 0 stat_vid_end_out r 0 end of video data write to memory event offset 0x10 6fe4 interrupt enable 31:10 unused - 9 ien_aux_ovrflw r/w 0 auxiliary buffer over?w event 8 ien_vid_ovrflw r/w 0 video buffer over?w event 7 ien_win_seqbrk r/w 0 windower sequence break event 6 ien_fid_seqbrk r/w 0 field identi?r sequence break event 5 ien_line_thresh r/w 0 line counter threshold reached event 4 ien_aux_wrap r/w 0 auxiliary capture write pointer wrap around event 3 ien_aux_start_in r/w 0 start of auxiliary data acquisition event 2 ien_aux_end_out r/w 0 end of auxiliary data write to memory event 1 ien_vid_start_in r/w 0 start of video data acquisition event 0 ien_vid_end_out r/w 0 end of video data write to memory event offset 0x10 6fe8 interrupt clear 31:10 unused - 9 clr_aux_ovrflw w 0 auxiliary buffer over?w event 8 clr_vid_ovrflw w 0 video buffer over?w event 7 clr_win_seqbrk w 0 windower sequence break event 6 clr_fid_seqbrk w 0 field identi?r sequence break event 5 clr_line_thresh w 0 line counter threshold reached event 4 clr_aux_wrap w 0 auxiliary capture write pointer wrap around event 3 clr_aux_start_in w 0 start of auxiliary data acquisition event 2 clr_aux_end_out w 0 end of auxiliary data write to memory event 1 clr_vid_start_in w 0 start of video data acquisition event 0 clr_vid_end_out w 0 end of video data write to memory event offset 0x10 6fec interrupt set table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-33 31:10 unused - 9 set_aux_ovrflw w 0 auxiliary buffer over?w event 8 set_vid_ovrflw w 0 video buffer over?w event 7 set_win_seqbrk w 0 windower sequence break event 6 set_fid_seqbrk w 0 field identi?r sequence break event 5 set_line_thresh w 0 line counter threshold reached event 4 set_aux_wrap w 0 auxiliary capture write pointer wrap around event 3 set_aux_start_in w 0 start of auxiliary data acquisition event 2 set_aux_end_out w 0 end of auxiliary data write to memory event 1 set_vid_start_in w 0 start of video data acquisition event 0 set_vid_end_out w 0 end of video data write to memory event offset 0x10 6ff4 powerdown 31 power_down rw 0 0 = normal operation 1 = powerdown mode 30:0 reserved offset 0x10 6ffc module id 31: 16 mod_id r 011a module id unique 16-bit code 15: 12 rev_major r 3 major revision counter 11: 8 rev_minor r 0 minor revision counter 7: 0 app_size r 00 aperture size 0 = 4 kb table 10: video input processor (vip) 1 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 12: video input processor 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 12-34
1. introduction the fast general purpose output (fgpo) module is a high-bandwidth (up to 400 mbytes/sec) output data channel. the fgpo outputs data in 8, 16, and 32-bit widths. the fgpo operates in two main modes: record output or message passing may be used as a versatile interface with streaming data receivers at rates from dc to 100 mhz may be used as a transmitter port for inter-trimedia unidirectional message passing allows optional synchronization with external control signals allows optional generation of external control signals allows optional output at selected timestamp times allows optional output of variable message/record lengths allows continuous data output transfers using dma transfers from two main memory buffers chapter 13: fgpo: fast general purpose output pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-2 1.1 fgpo overview figure 1 shows the top level connection of the fgpo module to the mmio and mtl busses within the pnx15xx series. all external fgpo signals are registered and routed through the output router module before leaving the pnx15xx series. latency buffering of data and endian conversion is done in the mtl dtl adapter. all fgpo register access is through the mmio dtl adapter. figure 2 shows the basic sections of the fgpo module. figure 1: top level block diagram dtl initiator mmio dtl adapter dtl target dtl initiator dtl initiator fgpo module output router vdo pads mmio bus dtl target dtl target mtl bus mtl dtl adapter clock block 64 32 32 32 32 32 figure 2: fgpo module block diagram dtl mmio i/f dtl initiator dtl initiator data header dma engine fifo data output engine timestamp fgpo_start fgpo_stop fgpo_data 8/16/32 fgpo_rec_sync fgpo_buf_sync
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-3 1.2 fgpo to vdo pin mapping fgpo_start (fgpo_rec_start) maps to vdo_d[32] fgpo_stop (fgpo_buf_start) maps to vdo_d[32] fgpo_clk from clock module maps to vdo_c2 vdo_d[31:0] mapping depends on the vdo_mode (output router) register settings, see chapter 3 system on chip resources . 1.3 dtl mmio interface this block contains all of the programmable registers used by the fgpo module accessed through the mmio bus. refer to section 4. for registers description. this block also handles clock domain crossing between the mmio bus clock and the fgpo module clock. 1.4 header initiator if either fgpo_ctl.tstamp_select or fgpo_ctl.var_length bits are set this dtl initiator will read the record/message timestamp and variable length ?lds. the variable length information is passed on to the dma engine to issue a read request from memory. the timestamp information is passed to the data output engine for a timestamp trigger point. the mtl dtl adapter for this dtl port contains a 2x8 (16 byte) fifo. 1.5 data initiator issues main memory read requests for all data samples. the mtl dlt adapter for this dtl port contains a 128x8 (1024 byte) fifo. 1.6 record output mode this mode allows the fgpo to read and transmit structured record data from main memory to the outside world. the start of a record may be triggered by reaching an absolute time (timestamp), by expiration of a counted gap between records, or by a synchronized external transition on the fgpo_rec_sync pin. the switching of buffers may also be triggered by a synchronized external transition on the fgpo_buf_sync pin. a record start control signal is generated at the start of each record on the fgpo_start (fgpo_rec_start) pin. output starts from a new location in the buffer for each record. successive records are output until the programmed number of records in a buffer is exhausted, then the alternate buffer is used. a buffer start control signal is generated at the start of each new buffer on the fgpo_stop (fgpo_buf_start) pin. this allows the output of video frames consisting of multiple line records, synchronized by a frame or ?ld synchronization signal.
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-4 1.7 message passing mode this mode allows the fgpo to read and transmit messages from main memory to either an fgpi unit on another pnx15xx series or a pnx1300 series vi in message passing mode. one fgpo can broadcast to multiple receiving fgpis. no data interpretation is done. each message from the sender is read from a separate message location in the memory buffer. message start and stop is signaled by the sender by separate fgpo_start and fgpo_stop control signals.
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-5 2. functional description table 1: module signal pins signal type description clk_fgpo input from clock module. external fgpo clock on vdo_c2 pin is connected to the clock module. fgpo data and control signals are output at each rising edge on clk_fgpo. use the pnx15xx series clock module to change clk_fgpo characteristics. fgpo_rec_sync input from external pad. in external record/message sync mode a programmable transition on this pin will trigger the output of a record or message after a synchronization delay of 4 fgpo clock cycles. if the transition occurs before the fgpo has ?ished the output of a previous record or message, the transition will be ignored. fgpo_buf_sync input from external pad. in external buffer sync mode a programmable transition on this pin will start a new buffer after a synchronization delay of 4 fgpo clock cycles. if the transition occurs before the fgpo has ?ished the current buffer, the transition will be ignored. fgpo_start or fgpo_rec_start output to external pad vdo_d[32] via output router. message passing mode: a positive pulse output on this pin indicates the start of a message. the pulse may be programmed to occur one clock before or at the same clock with the ?st valid data sample. record mode: a positive pulse output on this pin indicates the start of a record. the pulse may be programmed to occur one clock before or at the same clock with the ?st valid data sample or a positive pulse lasting as long as valid data samples are output.
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-6 2.1 stopping clk_fgpo for output ?w control some users may wish to supply the fgpo clock externally. the clock module can be set up to receive the clock on vdo_c2 and drive clk_fgpo with that signal. this would allow the external world to stop the fgpo clock (when low) for ow control. all fgpo registers can be accessed (read/write) while clk_fgpo is inactive without any bus time-outs. 2.2 reset fgpo is reset by any pnx15xx series system reset or by setting the software_reset bit fgpo_soft_rst register. remark: software_reset does not reset mmio bus interface registers. any dma transfers will be aborted during a software_reset. all registers reset to the reset value shown in the register description section. 2.3 base addresses two base address registers are used to point to main memory buffers in a double buffering scheme. addresses are forced into 32-bit address alignment. fgpo_stop or fgpo_buf_start output to external pad vdo_d[33] via output router. message passing mode: a programmable pulse on fgpo_stop indicates the end of a message. this pulse may be programmed to be a one clock pulse concurrent with the last data sample, or a pulse lasting as long as valid data samples are output. record capture mode: a programmable pulse on fgpo_buf_start indicates the start of a new buffer. the pulse may be programmed to occur one clock before or at the same clock with the ?st valid data sample for the buffer or a positive pulse lasting as long as each buffer is active. or a positive pulse lasting as long as buffer 2 is active. fgpo_data output to external pad vdo_d[31:0] via output router. general purpose high speed sample data output changing on each active edge of clk_fgpo. in 8-bit mode data is placed on fgpo_data7:0]. in 16-bit mode data is placed on fgpo_data[15:0]. fgpo_interrupt output interrupt status connects to the trimedia processor in the pnx15xx series. table 1: module signal pins ?ontinued signal type description
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-7 2.4 sample (data) size data size (width) per sample is set to either 8, 16, or 32-bit using fgpo_ctl.data_size bit ?ld. for 8-bit samples, four samples are packed into one 32-bit word. for 16-bit samples, two samples are packed 2 into one 32-bit word. packed data is read from memory in full 32-bit words. byte order, with which the data is read from memory, is controlled by the global pnx15xx series endian mode. the endian state only affects 16 and 32-bit sample sizes. 2.5 record or message size the number of samples per record is set by fgpo_rec_size ?ld. this is amount of data that will be output after each record or message start event unless the fgpo_ctl.var_length bit is set. if the fgpo_ctl.var_length bit is set the length of a record or message is set by the value of the second 32-bit word read from the header attached to the record or message. valid values are in the range of 2 to 2 24 - 1. remark: the fgpi has a minimum message size of 2 or 3. see fgpi module specification for more information. 2.6 records or messages per buffer the number of records or messages per buffer is set by fgpo_size register. valid values are in the range of 1 to 2 24 - 1. 2.7 stride if the number of records or messages per buffer is greater than one, the address stride has to be programmed into the fgpo_stride register. output starts at a new location in the current buffer on each record or message start event. after output starts a new address is generated by adding the contents of the fgpo_stride register to the previous starting address. care must be taken that fgpo_stride is greater than or equal to fgpo_rec_size. add 8 if either tstamp_select or var_length bits are set. 2.8 interrupt events the fgpo_ir_status register contains status and interrupt event status. to generate an interrupt to the trimedia processor the corresponding fgpo_ir_ena bit must be set. to clear an interrupt event (acknowledge the interrupt) a ??must be written to the corresponding fgpo_ir_clr bit. the fgpo_ir_set register can be used to generate software interrupts.
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-8 2.8.1 buf1done and buf2done interrupts when the number of records or messages output from a main memory buffer equals the value in the fgpo_size register an associated buffer done interrupt will be generated. remark: this interrupt is generated when the fgpo engine finishes sending the last sample from the last record/message from the associated main memory buffer. 2.8.2 thresh1_reached and thresh2_reached interrupts when fgpo_nrecn (the number of records or messages output from memory buffer n) equals the contents of the fgpo_threshn register then the associated threshn_reached bit will be set in the fgpo_ir_status register. the threshn_reached condition is ?ticky?and can only be cleared by software writing a ??to the fgpo_ir_clr.threshn_reached_ack bit. remark: this interrupt is generated when the fgpo engine finishes reading the last sample from the threshold record/message number from main memory and not when the last sample from the threshold record/message number is output. 2.8.3 underrun interrupt if software fails to assign a new buffer (update fgpo_basen register) and perform an interrupt acknowledge (clear bufndone interrupt) before both buffers are done, the interrupt event fgpo_ir_status.underrun will be set and the output of samples will stop. this happens when the fgpo switches to a buffer for which: a buffer done event has occurred and the buffer done interrupt has not been acknowledged and the corresponding enable bit is set and a new record or message start event has arrived output continues upon receipt of either buf1done_ack or buf2done_ack or both. refer to figure 4 on page 13- 11 to see which buffer output resumes from. the underrun condition is ?ticky?and can only be cleared by software writing a ??to the underrun_ack bit. 2.8.4 mbe interrupt a memory bandwidth error (mbe) interrupt is generated when no data samples care available during a record or message transfer. during the time mbe state exists the last valid data sample will be output on the fgpo_data pins. therefore one or more data samples will be added to the message until the adapter fifo contains valid data samples. then sample output resumes. for example if fgpo is set to send a message with 6 samples and an mbe occurs before d3 is output, i.e. d3 has not yet
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-9 reached the fgpo from the memory, then d2 remains on the data bus until d3 is available. therefore extra samples are sent and could be detected by fgpi with an overflow condition is the message has a know lenght. the mbe condition is ?ticky?and can only be cleared by software writing a ??to the fgpo_ir_clr.mbe_ack bit. however inside fgpo it is edge triggerred, i.e. if the cpu clears the mbe interrupt while fgpo is still in mbe state the sticky bit is indeed cleared and will not get set again unless fgpo gets out of the mbe state and comes back to it. in the later case, yet another mbe interrupt will be generated. software must not disable fgpo upon and mbe occuring. it should let fgpo reach the buf{1,2}done state before disabling fgpo. 2.9 record or message counters the registers fgpo_nrec1 and fgpo_nrec2 count the number of complete records or messages output. the counters are incremented when a record or message stop event is seen. the counters are cleared to zero when the associated fgpo_basen register is updated. reading a fgpo_nrecn register while the associated buffer is active may not return the actual transfer count (can be less than or equal to the actual count) due to clock domain crossing logic. the best time to read a fgpo_nrecn register is during the associated bufndone interrupt service routine as the counter is not updated during this time. see section 2.8.2 thresh1_rea ched and thresh2_rea ched interr upts for information on how to use fgpo_nrecn while the associated buffer is active. figure 3: back-to-back message passing example clk_fgpo internal mbe state fgpo_start fgpo_stop fgpo_data xxxxx d1 d2 d3 d4 d5 d6 xxx
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-10 2.10 timestamp if enabled, by setting fgpo_ctl.tstamp_select bit to ?? an 8-byte header is read from memory before the data. the ?st 32-bit word contains the start time (timestamp) of the record or message. the second 32-bit word may contain the length of the record or message if the var_length bit is set, else the contents are ignored. the timestamp clock is derived from the main timestamp clock which runs at 13.5 mhz when the gpio module module is clocked by the 108 mhz clock. remark: the length of the header is not included in the fgpo_rec_size value but must be included in the fgpo_stride value. if both fgpo_ctl.tstamp_select and fgpo_ctl.var_length bits are set, then the timestamp word is read from memory before the length word. enabling timestamp mode overrides all other buffer and record synchronization. 2.11 variable length if enabled, by setting fgpo_ctl.var_length bit to ?? an 8-byte header is read from memory before the data. the ?st 32-bit word may contain the start time (timestamp) of the record or message if tstamp_select is set, else the contents are ignored. the second 32-bit word contains the length of the record or message. remark: the length of the header is not included in the fgpo_rec_size value but must be included in the fgpo_stride value. if both fgpo_ctl.tstamp_select and fgpo_ctl.var_length bits are set, then the timestamp word is read from memory before the length word. in message mode, if the message length read from the header is greater than the value programmed into the fgpo_rec_size register then the message will be truncated to the length contained in the fgpo_rec_size register. 2.12 output time registers to help determine the actual time when a transfer took place there are the fgpo_time1 and fgpo_time2 registers. these registers hold the time when the last sample from a buffer is sent out. this serves to observe the actual departure time in non-timestamp operation modes. 2.13 double buffer operation figure 4 shows the major states associated with double buffering. in the following discussion a buffer start event means either the current buffer is done or that an external buffer sync event tells the fgpo to terminate the current buffer and switch to the next buffer. the exact semantics depends on the operating mode of the fgpo. upon reset (hardware or software), all status and control bits are placed in the reset condition and no buffer is active. once software has programmed the required parameters, it is safe to enable output by setting output_enable_1 and
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-11 output_enable_2. buffer 1 will become the active buffer ?st. starting with the next record or message start event samples will be output from buffer 1 until either output is disabled or buffer 1 is terminated by a buffer start event. double buffer operation may be terminated by disabling the next buffer to which the fgpo will switch to. this is done by clearing the associated fgpo_ctl.output_enable_n bit. 2.14 single buffer operation single buffer operation may be enabled by only setting the fgpo_ctl.output_enable_1 bit. when buffer 1 is done, sample output will stop until the buf1done_ack is received. 3. operation 3.1 both operating modes 3.1.1 setup initialize all registers except the fgpo_ctl register, ?st, then load the fgpo_ctl register with the output_enable_1 and output_enable_2 bits set. figure 4: double buffer major states active = buf1 buf2done buf1done buffer 1 done active = buf2 ack buffer 1 active = buf1 buf2done buffer 2 done ack buffer 2 underrun buf1done active = buf2 buffer 2 done buffer 1 done ack1 &!ack2 !ack1 & ack2 ack1 & ack2 start
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-12 3.1.2 interrupt service routines software must update the fgpo_basen register value (where n is the number of the buffer that interrupted with a buffer done interrupt) before clearing the buffer done interrupt ?g. this must be done even if the base address of the buffer does not change. 3.1.3 optimized dma transfers the ddr memory controller used in the pnx15xx series is optimized for 128-byte block transfers on 128-byte address boundaries. to keep main memory bus traf? at a minimum the programmer should program the fgpo_base1 and fgpo_base2 with bits [6:0] = 0000000 and program the fgpo_stride to multiples of 128. 3.1.4 terminating dma transfers during the next-to-last bufndone interrupt service routine turn off (set to ?? the associated fgpo_ctl.output_enable_n bit. during the last bufndone interrupt service routine turn off (set to ?? the associated fgpo_ctl.output_enable_n bit, the fgpo is now idle 3.1.5 signal edge de?itions the fgpo uses only the rising edge of clk_fgpo. if the negative edge of an external clock needs to be used, program the pnx15xx series clock module to invert the external clock for the fgpo. figure 5: signal edge de?ition clk rising edge sample point must be low 1 clock cycle before going active sample point must be high 1 clock cycle before going active falling edge clk (for pins: fgpo_start, fgpo_rec_start, fgpo_stop, fgpo_buf_start)
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-13 3.2 message passing mode if fgpo_rec_size is not a multiple of 4 bytes, the message will be read from main memory as a series of 32-bit words. only the last word is partially used. message start is signaled on the fgpo_start pin and message stop is signaled on the fgpo_stop pin. see fgpo_ctl.msg_start and fgpo_ctl.msg_stop for selecting which edge will be active. figure 6 illustrates an example of a two 8-sample message transfer. the message start event is set to the falling edge of fgpo_start and the message stop event is set to the rising edge of fgpo_stop. message mode requires both fgpo_start and fgpo_stop signals to operate. external buffer sync is not used with message mode. buffers are switched when the number of messages sent equals the value programmed into the fgpo_size register. the minimum message size is 2. fgpo_rec_size must be programmed greater than 1. if the outgoing message length is greater than the value programmed into the fgpo_rec_size register, the message is truncated. 3.3 pnx1300 series message passing mode pnx1300 series message passing mode can be emulated by setting fgpo_size to 1 and only enabling buffer 1 (fgpo_ctl.output_enable_1 = ??. 3.4 record output mode if fgpo_rec_size is not a multiple of 4 bytes, the record will be read from main memory as a series of 32-bit words. only the last word is partially used. record start is signaled on the fgpo_start (fgpo_rec_start) pin. see fgpo_ctl.msg_start (rec_sync) for selecting which edge will be active. buffer switching is signaled on the fgpo_stop (fgpo_buf_start) pin. see fgpo_ctl.msg_stop (buf_sync) for selecting which buffer sync method will be used. figure 6: back-to-back message passing example clk_fgpo fgpo_start fgpo_stop fgpo_data xxxxx d1 d2 d3 d4 d5 d6 d7 d8 xxx
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-14 3.4.1 record synchronization events starting output of sample data for each record is signaled by a output start event (selected by the fgpo_ctl.rec_sync bits): a rising edge on fgpo_rec_sync pin a falling edge on fgpo_rec_sync pin wait fgpo_rec_gap clock cycles before starting next record, start ?st record immediately wait for timestamp event occur immediately after the previous buffer is sent or when output is enabled the record ends by reaching the programmed record size in the fgpo_rec_size register or by the next record start event, whichever comes ?st. it takes 4 fgpo clock cycles to synchronize and react to events on the fgpo_rec_sync pin in external record sync mode. if timestamps are enabled the output is started on the next fgpo clock tick after the timestamp event. 3.4.2 buffer synchronization events each buffer is started by a buffer start event. (selected by the fgpo_ctl.buf_sync bits): a rising edge on fgpo_buf_sync pin a falling edge on fgpo_buf_sync pin alternating rising and falling edges on fgpo_buf_sync pin, starting with the next rising edge on fgpo_buf_sync pin alternating rising and falling edges on fgpo_buf_sync pin, starting with the next falling edge on fgpo_buf_sync pin wait fgpo_buf_sync clock cycles before starting next buffer, start ?st buffer immediately occur immediately after the previous buffer is sent or when output is started the fgpo_buf_sync signal will only be observed after the current buffer is ?ished. it takes 4 fgpo clock cycles to synchronize and react to events on the fgpo_buf_sync pin in external buffer sync mode.
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-15 4. register descriptions 4.1 mode register setup table 2: register summary offset name clock domain description 0x07,1000 fgpo_ctl fgpo controls operational mode and enables/disables dma transfers 0x07,1004 fgpo_base1 mmio starting address for ?st buffer 0x07,1008 fgpo_base2 mmio starting address for second buffer 0x07,100c fgpo_size fgpo number of records/messages per buffer 0x07,1010 fgpo_rec_size fgpo size of record/message in samples 0x07,1014 fgpo_stride fgpo address stride between records/messages 0x07,1018 fgpo_nrec1 mmio number of records/messages transferred from buffer 1 0x07,101c fgpo_nrec2 mmio number of records/messages transferred from buffer 2 0x07,1020 fgpo_thresh1 fgpo interrupt threshold for buffer 1 0x07,1024 fgpo_thresh2 fgpo interrupt threshold for buffer 2 0x07,1028 fgpo_rec_gap fgpo delay between records/messages 0x07,102c fgpo_buf_gap fgpo delay between buffers 0x07,1030 fgpo_time1 fgpo timestamp when buffer 1 was ?ished 0x07,1034 fgpo_time2 fgpo timestamp when buffer 2 was ?ished 0x07,1038 - 0x07,1fdc reserved n/a 0x07,1fe0 fgpo_ir_status mmio module interrupt status 0x07,1fe4 fgpo_ir_ena mmio module interrupt enables 0x07,1fe8 fgpo_ir_clr mmio module interrupt clear (interrupt acknowledge) 0x07,1fec fgpo_ir_set mmio module interrupt set (debug) 0x07,1ff0 fgpo_soft_rst mmio module software reset 0x07,1ff4 fgpo_if_dis mmio module interface disable 0x07,1ff8 fgpo_mod_id_ex t mmio module id extension 0x07,1ffc fgpo_mod_id mmio module id table 3: fast general purpose output (fgpo) bit symbol acces s value description fpgo registers offset 0x07,1000 fgpo_ctl 31:22 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 21 polarity_in r/w 0 determines clk_fgpo clock sampling edge for fgpo_rec_sync and fgpo_buf_sync inputs: 0 = use same active edge as for outputs 1 = use alternate active edge as for outputs
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-16 20:19 buf_start / msg_stop r/w 00 in record mode: selects the buffer sync output on fgpo_stop at the start of a new buffer: 00 = a one clock positive pulse concurrently with the ?st data sample of each buffer output. 01 = a one clock positive pulse one clock before the ?st data sample of each buffer output. 10 = a positive pulse asserted when any buffer is active, negated while waiting for a buffer sync. 11 = a positive pulse asserted when data from buffer 2 is valid. in message mode: selects message stop output on fgpo_stop at the end of a message: 00 = a one clock positive pulse concurrently with the last data sample for each message 01 = a positive pulse asserted when message data is valid. 10 = same as 00 above 11 = same as 01 above 18 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 17:16 rec_start / msg_start r/w 00 selects record/message start output on fgpo_start at the beginning of a record/message: 00 = a one clock positive pulse concurrently with the ?st data sample of each record/message output. 01 = a one clock positive pulse one clock before the ?st data sample of each record/message output. 10 = a positive pulse asserted as long as valid data is output, negated while waiting for record/message sync event on fgpo_rec_sync . 11 = same as 00 above. 15 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. table 3: fast general purpose output (fgpo) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-17 14 polarity_clk r/w 0 externally selects active clock edge for clk_fgpo via fgpo_clk_pol 0 = rising edge 1 = falling edge note: this bit not used in the pnx15xx series. all fgpo clock control is in the clock module. 13 output_enable_2 r/w 0 enable output from buffer 2. this bit, along with bit 12 below, start and stop fgpo dma activity. 12 output_enable_1 r/w 0 enable output from buffer 1. this bit, along with bit 13 above, start and stop fgpo dma activity. if output from only one buffer is desired, this bit must be used to start/stop dma. 11 mode r/w 0 0 = record mode 1 = message mode 10 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 9:8 sample_size r/w 00 encodes size of data samples output on fgpo_data : 00 = 8-bit data samples 01 = 16-bit data samples 10 = 32-bit data samples 11 = same as 10 above table 3: fast general purpose output (fgpo) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-18 7:5 buf_sync r/w 000 encodes function of fgpo_buf_sync in record mode. encodes to 000 in message mode: 000 = no buffer sync, ignores fgpo_buf_sync input. switch to alternate buffer at eob (end-of-buffer). start ?st buffer immediately after output_enable_1 (bit 12 above) is set. 001 = wait fgpo_buf_gap clock pulses before switch to alternate buffer. ignores fgpo_buf_sync input. start ?st buffer immediately after output_enable_1 (bit 12 above) is set. 010 = same as 000 above. 011 = same as 001 above. 100 = switch buffers on rising edge on fgpo_buf_sync input. wait for next rising edge on fgpo_buf_sync input, after output_enable_1 (bit 12 above) is set, to start ?st buffer. 101 = switch buffers on rising edge on fgpo_buf_sync input. wait for next rising edge on fgpo_buf_sync input, after output_enable_1 (bit 12 above) is set, to start ?st buffer. 110 = switch buffers on rising edge on fgpo_buf_sync input. wait for next rising edge on fgpo_buf_sync input, after output_enable_1 (bit 12 above) is set, to start ?st buffer. 111 = switch buffers on rising edge on fgpo_buf_sync input. wait for next rising edge on fgpo_buf_sync input, after output_enable_1 (bit 12 above) is set, to start ?st buffer. 4 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 3:2 rec_sync r/w 00 encodes function of fgpo_rec_sync in record/message mode. 00 = no record/message sync, ignores fgpo_rec_sync input. switch to next record at eor/eom (end-of-record / end-of- message). start ?st record/message immediately after output_enable_1 (bit 12 above) is set. 01 = wait fgpo_rec_gap clock pulses before starting next record/message. ignores fgpo_buf_sync input. start ?st record/message immediately after output_enable_1 (bit 12 above) is set. 10 = start record/message on fgpo_rec_sync rising edge. 11 = start record/message on fgpo_rec_sync falling edge. table 3: fast general purpose output (fgpo) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-19 1 tstamp_select r/w 0 0 = the rec_sync and buf_sync ?lds control record/message sync and buffer sync events. 1 = overrides buf_sync to ?o sync mode: 000? rec_sync ?ld is ignored. causes the fgpo to read an 8-byte record/ message header where the ?st 4-bytes contains the 32-bit timestamp word. record/message will start when the internal timestamp matches the timestamp in the header. note : the length of the header (8 bytes) is not included in the record/message size in fgpo_size register but is included in the stride (fgpo_stride register). 0 var_length r/w 0 0 = the length of each record/message is contained in the fgpo_rec_size register. 1 =causes the fgpo to read an 8-byte record/message header where the second 4-bytes contains the 32-bit record/message length word. record mode : the value read from the header overrides the contents of the fgpo_rec_size register. message mode : if the message length read from the header is greater than the value in the fgpo_rec_size register then the message is truncated to fgpo_rec_size samples. note : the length of the header (8 bytes) is not included in the record/message size in fgpo_size register but is included in the stride (fgpo_stride register). offset 0x07,1004 fgpo_base1 31:2 base1 r/w 0 32-bit word aligned address pointing to buffer 1 base. 1:0 reserved r 0 always 0. offset 0x07,1008 fgpo_base2 31:2 base2 r/w 0 32-bit word aligned address pointing to buffer 2 base. 1:0 reserved r 0 always 0. offset 0x07,100c fgpo_size 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 size r/w 0 number of records/messages per buffer. range: 1 to 2 24 -1 offset 0x07,1010 fgpo_rec_size 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 rec_size r/w 0 number of samples per record/message. range: 2 to 2 24 -1 offset 0x07,1014 fgpo_stride 31:2 stride r/w 0 address stride between records/messages table 3: fast general purpose output (fgpo) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-20 4.2 status registers 1:0 reserved r 0 always 0. offset 0x07,1018 fgpo_nrec1 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 nrec1 r 0 number of records/messages output from buffer 1. cleared to zero when fgpo_base1 register is written to. offset 0x07,101c fgpo_nrec2 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 nrec2 r 0 number of records/messages output from buffer 2. cleared to zero when fgpo_base1 register is written to. offset 0x07,1020 fgpo_thresh1 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 thresh1 r/w 0 thresh1_reached interrupt generated when fgpo_nrec1 count equals this register value. range: 1 to 2 24 -1 offset 0x07,1024 fgpo_thresh2 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 thresh2 r/w 0 thresh2_reached interrupt generated when fgpo_nrec2 count equals this register value. range: 1 to 2 24 -1 offset 0x07,1028 fgpo_rec_gap 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 rec_gap r/w 0 clock delay after a record/message is output before the next record/ message is output. range: 1 to 2 24 -1 offset 0x07,102c fgpo_buf_gap 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 buf_gap r/w 0 clock delay after a buffer is output before the next buffer is output. range: 1 to 2 24 -1 offset 0x07,1030 fgpo_time1 31:0 time1 r 0 holds timestamp when buffer 1 completed. offset 0x07,1034 fgpo_time2 31:0 time2 r 0 holds timestamp when buffer 2 completed. table 3: fast general purpose output (fgpo) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-21 table 4: status registers bit symbol acces s value description standard registers offset 0x07,1fe0 fgpo_ir_status 31:8 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 7 buf1_active r 0 1 when buffer 1 is active 6 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 5 mbe r 0 memory bandwidth error detected. 4 underrun r 0 buffer underrun detected. 3 thresh2_reached r 0 buffer 2 threshold reached. 2 thresh1_reached r 0 buffer 1 threshold reached. 1 buf2_done r 0 buffer 2 done. 0 buf1_done r 0 buffer 1 done. offset 0x07,1fe4 fgpo_ir_ena 31:6 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 5 mbe_ena r/w 0 memory bandwidth error interrupt enable 4 underrun_ena r/w 0 buffer underrun interrupt enable 3 thresh2_reached_ ena r/w 0 buffer 2 threshold interrupt enable 2 thresh1_reached_ ena r/w 0 buffer 2 threshold interrupt enable 1 buf2_done_ena r/w 0 buffer 2 done interrupt enable 0 buf1_done_ena r/w 0 buffer 1 done interrupt enable offset 0x07,1fe8 fgpo_ir_clr 31:6 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 5 mbe_ack r/w 0 memory bandwidth error interrupt acknowledge 4 underrun_ack r/w 0 buffer underrun interrupt acknowledge 3 thresh2_reached_ ack r/w 0 buffer 2 threshold interrupt acknowledge 2 thresh1_reached_ ack r/w 0 buffer 2 threshold interrupt acknowledge 1 buf2_done_ack r/w 0 buffer 2 done interrupt acknowledge 0 buf1_done_ack r/w 0 buffer 1 done interrupt acknowledge offset 0x07,1fec fgpo_ir_set 31:6 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 5 mbe_set r/w 0 set memory bandwidth error interrupt 4 underrun_set r/w 0 set buffer underrun interrupt
philips semiconductors pnx15xx series volume 1 of 1 chapter 13: fgpo: fast general purpose output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 13-22 3 thresh2_reached_ set r/w 0 set buffer 2 threshold interrupt 2 thresh1_reached_ set r/w 0 set buffer 2 threshold interrupt 1 buf2_done_set r/w 0 set buffer 2 done interrupt 0 buf1_done_set r/w 0 set buffer 1 done interrupt offset 0x07,1ff0 fgpo_soft_rst 31:1 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 software_reset r/w 0 1 = asserts an internal fgpo reset the effects are: all fgpo registers are reset all pending interrupts are removed any pending dma reads are aborted all state machines return to their reset state all clocks must be running before the soft reset can complete. this bit will clear after the reset completes. offset 0x07,1ff4 fgpo_if_dis 31:1 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 disable_bus_if r/w 0 1 = all writes to fgpo mmio space (except this register) will be ignored. all reads (except this register) will return 0x00000000. the fgpo module clock can be stopped low to save power when this bit is set. offset 0x07,1ff8 fgpo_mod_id_ext 31:0 module_id_ext r 0 32-bit module id extension offset 0x07,1ffc fgpo_mod_id 31:16 mod_id r 0x014c 16-bit module id code. 15:12 major_rev r 0 4-bit major revision code 11:8 minor_rev r 0x2 4-bit minor revision code 7:0 aperature r 0 8-bit aperture code. 0x00 = 4k byte aperture. table 4: ?ontinued status registers bit symbol acces s value description
1. introduction the fast general purpose input (fgpi) module is a high-bandwidth (up to 400 mbytes/sec) input data channel. the fgpi packs either four 8-bit, or two 16-bit, or one 32-bit data sample(s) into one 32-bit word which is sent to main memory via dma. the fgpi operates in two main modes: record capture or message passing may be used as a versatile interface with streaming data sources at rates from dc to 100mhz may be used as a receiver port for inter-trimedia unidirectional message passing allows optional synchronization with external control signals allows optional insertion of timestamp into message/record packet sent to memory allows optional insertion of message/record length into message/record packet sent to memory allows continuous data transfer using dma transfers to two main memory buffers chapter 14: fgpi: fast general purpose interface pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-2 1.1 fgpi overview refer to figure 1 . this block diagram shows the top level connection of the fgpi module to the mmio and mtl busses within the pnx15xx series. all external fgpi signals are registered and routed through the input router module before being presented to the fpgi module. latency buffering of data and endian conversion is done in the mtl dtl adapter. all fgpi register access is through the mmio dtl adapter. figure 1: top level block diagram dtl initiator mmio dtl adapter dtl target dtl initiator dtl initiator fgpi module input router vdi pads mmio/dcs bus dtl target dtl target mtl bus mtl dtl adapter clock block 64 32 32 32 32 32
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-3 refer to figure 2 . this block diagram shows the basic sections of the fgpi module. 1.2 vdi to fgpi pin mapping vdi_d[32] maps to fgpi_start (fgpi_rec_start) vdi_d[33] maps to fgpi_stop (fgpi_buf_start) vdi_v2 maps to fgpi_d_valid vdi_c2 maps to clock module fgpi_clk input vdi_d[31:0] mapping depends on the vdi_mode (input router) register settings as described in the chapter 3 system on chip resources . 1.3 dtl mmio interface this block contains all of the programmable registers used by the fgpi module accessed through the mmio bus. refer to section 4. on page 14- 18 for register descriptions. this block also handles clock domain crossing between the mmio bus clock and the fgpi module clock. 1.4 data packer this block is used to pack incoming data samples into 32-bit words to be sent to main memory. this module also informs the dma engine when a valid 32-bit data word is ready to be loaded into the mtl dtl adapters fifo via the dtl initiators. figure 2: fgpi module block diagram dtl mmio i/f fgpi_data fgpi_d_valid fgpi_start fgpi_stop 8/16/32 data packer buffer sync timestamp 32 dma engine dtl initiator dtl initiator 32 32 length
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-4 1.4.1 8-bit sample packing mode sample data received on fgpi_data[7:0] will be packed into one 32-bit word as follows: sample 1 to word[7:0] sample 2 to word[15:8] sample 3 to word[23:16] sample 4 to word [31:24] 1.4.2 16-bit sample packing mode sample data received on fgpi_data[15:0] will be packed into one 32-bit word as follows: sample 1 to word[15:0] sample 2 to word[31:16] 1.4.3 32-bit sample mode sample data received on fgpi_data[31:0] will pass to word[31:0]. 1.5 record capture mode this mode allows the fgpi to receive and store structured record data. the start of a record may be triggered by a transition on the fgpi_start (fgpi_rec_start) pin. the active transition is programmed in the fgpi_ctl register bits [3:2]. recording starts at a new location in the current buffer for each record received. successive records are stored in the current buffer until the programmed number of records a buffer contains is reached. at this time the next buffer is activated and subsequent records are loaded into that buffer. a buffer sync recording mode is available. this mode will switch between alternate buffers on each active transition on the fgpi_stop (fgpi_buf_sync) pin. the active transition is programmed in the fgpi_ctl register bits [7:5]. this allows recording of video frames consisting of multiple line records synchronized by a frame sync of ?ld sync signal. a continuous raw capture mode is available when fgpi_ctl register bits [7:5] == 100 and bits [4:3] = 10. in this mode data is captured when ever fgpi_d_valid is asserted high. 1.6 message passing mode in message passing mode the fgpi can act as a receiver of data from the fgpo output from another pnx15xx series processor. the fgpi can also receive data from a pnx1300 series vo output in message passing mode.
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-5 one fgpo can broadcast to multiple fgpis by controlling the fgpi_d_valid pin. no data interpretation is done. each message from the sender is written to a separate memory location in the current buffer. message start is signaled by fgpi_start pin and message stop is signaled by the fpgi_stop pin.
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-6 2. functional description 2.1 reset fgpi is reset by any pnx15xx series system reset or by setting the software_reset bit in the fgpi_soft_rst register. table 1: module signal pins signal type description clk_fgpi input from clock module. external fgpi clock on vdi_c2 pin is connected to the clock module. fgpi data and control signals are sampled at each rising edge on clk_fgpi when fgpi_d_valid is asserted high. use the pnx15xx series clock module to change clk_fgpi characteristics. fgpi_d_valid input from external pad, vdi_v2 via input router. in all operating modes fgpi_d_valid is used to qualify data & control signals. fgpi_start (fgpi_rec_start), fgpi_stop (fgpi_buf_start), and fgpi_data will only be sampled when fgpi_d_valid is high during the rising edge of clk_fgpi. fgpi_start or fgpi_rec_start input from external pad, vdi_d[32] via input router. message passing mode: a programmable transition on fgpi_start (see fgpi_ctl register bits 3:2) indicates the start of a message. the message starts on the clk_fgpi edge when the transition was detected. record capture mode: a programmable transition on fgpi_rec_start (see fgpi_ctl register bits 3:2) indicates the start of a record. the record starts on the clk_fgpi edge when the transition was detected. fgpi_stop or fgpi_buf_start input from external pad, vdi_d[33] via input router. message passing mode: a programmable transition on fgpi_stop (see fgpi_ctl register bits 7:5) indicates the end of a message. the message ends on the clk_fgpi edge when the transition was detected. record capture mode: a programmable transition on fgpi_buf_start (see fgpi_ctl register bits 7:5) indicates the start of a new buffer. the new buffer starts on the clk_fgpi edge when the transition was detected. fgpi_data input from external pads, vdi_d[31:0] via input router. general purpose high speed data input sampled on the rising edge of clk_fgpi when fgpi_d_valid is high. fgpi_interrupt output interrupt status connects to the trimedia processor in the pnx15xx series. fgpi_intr_active output not used in the pnx15xx series. fgpi_clk_pol output not used in the pnx15xx series. fgpi_resetn output goes to the pnx15xx series input router module to reset its registers used in routing data to the fgpi module.
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-7 remark: software_reset does not reset mmio bus interface registers. any dma transfers will be aborted during a software_reset. all registers are reset to the reset value shown in the register description section. 2.2 base addresses two base address registers are used to point to main memory buffers in a double buffering scheme. addresses are forced into 32-bit address alignment. 2.3 sample (data) size data size (width) per sample is set to either 8, 16, or 32 bits using fgpi_ctl.sample_size bit ?ld. for 8-bit samples, four samples are packed into one 32-bit word. for 16-bit samples, two samples are packed 2 into one 32-bit word. byte order, with which the data is written to memory, is controlled by the global pnx15xx series endian mode. the endian state only affects 16 and 32-bit sample sizes. figure 3 shows how data is stored in memory if data input to the fgpi does not match the setting of the fgpi_ctl.sample_size bit ?ld. settings for the pnx15xx series input router will affect the ?nknown data?received. 2.4 record or message size in record mode: the number of samples per record is set by fgpi_rec_size ?ld. this is the amount of samples that will be captured after each record start event. in message mode: maximum number of samples per message is set by fgpi_rec_size ?ld. the end of a message is signaled by the active fgpi_stop edge. if the message length is greater than the programmed value in the fgpi_rec_size register, the message is truncated and a overflow interrupt is generated. figure 3: input data width not equal to sample size setting fgpi_ctl.sample_size = 32-bit 8-bit data input to fgpi 12 34 memory address a a+4 a+8 a+12 bit 0 bit 31 12 16-bit data input a a+4 fgpi_ctl.sample_size = 16-bit 8-bit data input to fgpi 1 2 a 3 4 a+4 unknown data
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-8 2.5 records or messages per buffer the number of records or messages per buffer is set by fgpi_size register. 2.6 stride if the number of records or messages per buffer is greater than one, the address stride has to be programmed into the fgpi_stride register. recording starts at a new location in the current buffer on each record or message start event. after recording starts a new address is generated by adding the contents of the fgpi_stride register to the previous starting address. care must be taken that fgpi_stride is greater than or equal to fgpi_rec_size. add 4 if tstamp_select is set. add 4 if var_length is set. 2.7 interrupt events the fgpi_ir_status register contains buffer status and interrupt event status. to generate an interrupt to the trimedia processor the corresponding fgpi_ir_ena bit must be set. to clear an interrupt event (acknowledge the interrupt) a ??must be written to the corresponding fgpi_ir_clr bit. the fgpi_ir_set register can be used to generate software interrupts. 2.7.1 buf1full and buf2full interrupts when the number of records or messages received and stored in a main memory buffer equals the value in the fgpi_size register an associated buffer full interrupt will be generated. remark: received records or messages are guaranteed to be in main memory when the bufndone interrupt is received. 2.7.2 thresh1_reached and thresh2_reached interrupts when fgpi_nrecn (the number of records or messages stored in memory buffer n) equals the contents of the fgpi_threshn register then the associated threshn_reached bit will be set in the fgpi_ir_status register. the threshn_reached condition is ?ticky?and can only be cleared by software writing a ??to the fgpi_ir_clr.threshn_reached_ack bit. warning: received records or messages are not guaranteed to be in main memory when the threshn_reached interrupt is received. the only interrupt that guarantees that the records or messages are in main memory are the bufndone interrupts. 2.7.3 overrun interrupt if software fails to assign a new buffer (update fgpi_basen register) and perform an interrupt acknowledge (clear bufnfull interrupt) before both buffers ?l up, the interrupt event fgpi_ir_status.overrun will be set and capture of samples will stop. this happens when the fgpi switches to a buffer for which:
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-9 a buffer full event has occurred and the buffer full interrupt has not been acknowledged and the corresponding enable bit is set and a new record or message start event has arrived capture continues upon receipt of either buf1full_ack or buf2full_ack or both. refer to figure 4 on page 14- 11 to see which buffer capture resumes in. the overrun condition is ?ticky and can only be cleared by software writing a ? to the fgpi_ir_clr.overrun_ack bit. 2.7.4 mbe interrupt a memory bandwidth error (mbe) interrupt is generated when received samples can not be loaded into the main memory adapter fifo. one or more data samples will be lost until the adapter fifo can accept samples. sample capture resumes at the correct address. the mbe condition is ?ticky?and can only be cleared by software writing a ??to the fgpi_ir_clr.mbe_ack bit. 2.7.5 overflow interrupt (message passing mode only) if the message length over?ws the value programmed in the fgpi_rec_size register, the message is truncated and the fgpi_ir_status.overflow interrupt will be generated. the overflow condition is ?ticky and can only be cleared by software writing a ? to the fgpi_ir_clr.overflow_ack bit. 2.8 record or message counters the registers fgpi_nrec1 and fgpi_nrec2 count the number of complete records or messages transferred to memory. the counters are incremented when a record or message stop event is seen. the counters are cleared to zero when the associated fgpi_basen register is updated. reading a fgpi_nrecn register while the associated buffer is active may not return the actual transfer count (can be less than or equal to the actual count) due to clock domain crossing logic. the best time to read a fgpi_nrecn register is during the associated bufnfull interrupt service routine as the counter is not updated during this time. see section 2.7.2 thresh1_rea ched and thresh2_rea ched interr upts for information on how to use fgpi_nrecn while the associated buffer is active. 2.9 timestamp if enabled, by setting fgpi_ctl.tstamp_select bit to ?? a 4-byte time-of-arrival word giving the record or message start event time is written to main memory before sample data. the timestamp clock is derived from the main timestamp clock which runs at 13.5 mhz when the gpio module module is clocked by the 108 mhz clock.
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-10 note: the length of the timestamp word is not included in the fgpi_rec_size value but must be included in the fgpi_stride value. if both fgpi_ctl.tstamp_select and fgpi_ctl.var_length bits are set, then the timestamp word is written to memory before the length word. 2.10 variable length if enabled, by setting fgpi_ctl.var_length bit to ?? a 4-byte length of record or message (number of samples received) word is written to main memory before sample data but after the timestamp word (if enabled). remark: the length of the var_length word is not included in the fgpi_rec_size value but must be included in the fgpi_stride value. 2.11 double buffer operation figure 4 presents the major states associated with double buffering. in the following discussion a buffer start event means either the current buffer is full or that an external buffer sync event tells the fgpi to terminate the current buffer and switch to the next buffer. the exact semantics depends on the operating mode of the fgpi. upon a system reset, all status and control bits are placed in the reset condition and no buffer is active. once software has programmed the required parameters, it is safe to enable capture by setting capture_enable_1 and capture_enable_2. buffer 1 will become the ?st active buffer. starting with the next record or message start event samples will be captured in buffer 1 until either capture is disabled or buffer 1 is terminated by a buffer start event. refer to figure 5 on page 14- 12 for how the fgpi handles buffer termination and switching during a transfer. when a buffer ?ls, or is stopped by a buffer start event, the last data sample is tagged by the fgpi so the memory controller will inform the fgpi when the buffer is written to main memory. when the tag is acknowledged the fgpi will issue a buf1full interrupt (if enabled). during this time buffer 2 will be capturing data samples.
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-11 double buffer operation may be terminated by disabling the next buffer to which the fgpi will switch to. this is done by clearing the associated fgpi_ctl.capture_enable_n bit. 2.12 single buffer operation single buffer operation may be enabled by only setting the fgpi_ctl.capture_enable_1 bit. when buffer 1 is full, sample capture will stop until the buf1full_ack is received. figure 4: double buffer major states active = buf1 buf2full buf1full buffer 1 full active = buf2 ack buffer 1 active = buf1 buf2full buffer 2 full ack buffer 2 overrun buf1full active = buf2 buffer 2 full buffer 1 full ack1 &!ack2 !ack1 & ack2 ack1 & ack2 start
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-12 2.13 buffer synchronization 3. operation 3.1 both operating modes 3.1.1 setup initialize all registers, except the fgpi_ctl register, ?st. then load the fgpi_ctl register with the capture_enable_1 and capture_enable_2 bits set. figure 5: buffer sync actions 1 23456 record n-1 7 89abc record n buffer #1 fgpi_buf_sync fgpi_buf_sync sampled during last record of buffer #1 will allow the record to ?ish being loaded into buffer #1 d ef ghi record n+1 1 23456 7 89abc d ef ghi buffer #2 1 23456 record n-1 7 89abc record n buffer #1 d ef ghi record n+1 1 23456 7 89 abc d e f g h i buffer #2 fgpi_buf_sync fgpi_buf_sync sampled during last record of buffer #1 will switch to buffer #2 after storing the last sample in fgpi_ctl[3:2] == 10 buffer #1. subsequent samples will be saved in buffer #2. note: the rest of buffer #1 is unde?ed. fgpi_ctl[3:2] == 00 or 01 1 23456 record n-1 7 89abc record n buffer #1 d ef ghi record n+1 1 23456 7 89abc d ef ghi buffer #2 fgpi_buf_sync fgpi_buf_sync sampled before last record of buffer #1 fgpi_ctl[3:2] == 00 or 01 will allow the record to ?ish being loaded into buffer#1 but record n will be loaded into buffer #2. note: the rest of buffer #1 is unde?ed. 1 23456 7 89abc d ef ghi 1 2345 6 7 89abc d ef ghi fgpi_buf_sync record n-1 record n record n+1 buffer #2 buffer #1 fgpi_ctl[3:2] == 10 fgpi_buf_sync sampled before last record of buffer #1 will switch to buffer #2 after storing the last sample in buffer #1. subsequent samples will be saved in buffer #2. note: the rest of buffer #1 is unde?ed.
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-13 3.1.2 interrupt service routines software must update the fgpi_basen register (where n is the number of the buffer that interrupted with a buffer full interrupt) before clearing the buffer full interrupt ?g. this must be done even if the base address of the buffer does not change. 3.1.3 optimized dma transfers the ddr memory controller used in the pnx15xx series is optimized for 128-byte block transfers on 128-byte address boundaries. to keep main memory bus traf? at a minimum the programmer should program the fgpi_base1 and fgpi_base2 with bits [6:0] = 0000000 and program the fgpi_stride to multiples of 128. 3.1.4 terminating dma transfers during the next-to-last bufnfull interrupt service routine turn off (set to ?? the associated fgpi_ctl.capture_enable_n bit. during the last bufnfull interrupt service routine turn off (set to ?? the associated fgpi_ctl.capture_enable_n bit, the fgpi is now idle. 3.1.5 signal edge de?itions the fgpi uses only the rising edge of clk_fgpi. if the negative edge of an external clock needs to be used, program the pnx15xx series clock module to invert the external clock for the fgpi. figure 6: signal edge de?ition clk rising edge sample point must be low 1 clock cycle before going active sample point must be high 1 clock cycle before going active falling edge clk (for pins: fgpi_start, fgpi_rec_start, fgpi_stop, fgpi_buf_start)
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-14 3.2 message passing mode only active clock edges where fgpi_d_valid is asserted ??allow data samples to be captured. if fgpi_rec_size is not a multiple of 4 bytes, the message will be written to main memory as a series of 32-bit words. only the last word is padded with zeroes in the unused bit positions. message start is signaled on the fgpi_start pin and message stop is signaled on the fgpi_stop pin. see fgpi_ctl.msg_start and fgpi_ctl.msg_stop for selecting which edge will be active. figure 7 illustrates an example of a two 8-sample message transfer. the message start event is set to the falling edge of fgpi_start and the message stop event is set to the rising edge of fgpi_stop. message mode requires both fgpi_start and fgpi_stop signals to operate. there is no external buffer sync available. buffers are switched when the number of messages received equals the value programmed into the fgpi_size register. if the incoming message length is greater than the value programmed into the fgpi_rec_size register, the message is truncated and the overflow interrupt is generated (if enabled). 3.2.1 minimum message/record size the minimum message size is 2 , that is, fgpi_rec_size must be programmed greater than 1. there is a limit to the message size when back-to-back messages are received. if the sample size is 32-bits and tstamp_select = ??and var_length = ? then the minimum message size is 3 (due to the insertion of 2 32-bit words into the message packet). figure 7: back-to-back message passing example clk_fgpi fgpi_d_valid fgpi_start fgpi_stop fgpi_data xxxxx d1 d2 d3 d4 d5 d6 d7 d8 xxx
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-15 3.3 pnx1300 series message passing mode pnx1300 series message passing mode can be emulated by setting fgpi_size to 1 and only enabling buffer 1 (fgpi_ctl.capture_enable_1 = ??. 3.4 record capture mode only active clock edges where fgpi_d_valid is asserted ??allow data samples to be captured. if fgpi_rec_size is not a multiple of 4 bytes, the record will be written to main memory as a series of 32-bit words. only the last word is padded with zeroes in the unused bit positions. record start is signaled on the fgpi_start (fgpi_rec_start) pin. see fgpi_ctl.msg_start (rec_sync) for selecting which edge will be active. buffer switching is signaled on the fgpi_stop (fgpi_buf_start) pin. see fgpi_ctl.msg_stop (buf_sync) for selecting which buffer sync method will be used. 3.4.1 record synchronization starting capture of sample data for each record is signaled by a record start event (selected by the fgpi_ctl.rec_sync bits): a rising edge on fgpi_start (fgpi_rec_start) pin a falling edge on fgpi_start (fgpi_rec_start) pin occur immediately after the previous buffer is ?led or when capture is started (see section 3.1.5 on page 14- 13 for signal de?itions for rising and falling edges). the record ends by reaching the programmed record size in the fgpi_rec_size register or by the next record start event, whichever comes ?st. for rising and falling edge record start events the record may reach the programmed record size before the next record start event starts a new record. in this case the fgpi will stop sampling data and wait for the next record start event to continue ?ling the current buffer. the record may also be terminated by receiving the next record start event before the end of the current record. in this case the record is only partially ?led, the content of the rest of the record is unde?ed. when no record sync is used data is sampled continuously. this leads to back-to- back recording of consecutive records, independent of the fgpi_start (fgpi_rec_start) pin state. each record is exactly the programmed size in the fgpi_rec_size register. 3.4.2 buffer synchronization refer to figure 5 on page 14- 12 for the following section. it is possible to further synchronize the recording of sample data to a buffer start event. (selected by the fgpi_ctl.buf_sync bits):
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-16 a rising edge on fgpi_stop (fgpi_buf_start) pin a falling edge on fgpi_stop (fgpi_buf_start) pin alternating rising & falling edges on fgpi_stop (fgpi_buf_start) pin, starting with a rising edge alternating rising & falling edges on fgpi_stop (fgpi_buf_start) pin, starting with a falling edge occur immediately after the previous buffer is ?led or when capture is started (see section 3.1.5 on page 14- 13 for signal de?itions for rising and falling edges). the buffer start event switches to a new buffer as soon as a concurrent or following record start event is detected if double buffering is enabled. for rising, falling, and alternate buffer start events the programmed number of records (fgpi_size) for the current buffer may be reached before the next buffer start event. if this happens the capture of data is stopped until the next buffer and record start events. if a record start event occurs before the buffer start event, it will be ignored. a buffer start event may occur before the next record start event. for rising, falling, and alternate buffer start events the current buffer may also be terminated by receiving a buffer start event before the programmed number of records (fgpi_size) is reached. if record start event is rising or falling then the current record will ?ish being loaded into the current buffer before switching to the next buffer. if record start event is ignored the current buffer is only partially ?led and the content of the remaining buffer is unde?ed. subsequent samples will be stored in the next buffer. when no buffer sync is used the fgpi_stop (fgpi_buf_start) pin is ignored. in this mode each buffer will contain fgpi_size records and buffer switching occurs immediately after a buffer ?ls. when no buffer or record sync is used data samples are sampled and stored continuously. this mode is called ?ree running?or ?aw capture? 3.4.3 setup and operation with input router vdi_mode[7] = 1 see the global register speci?ation for more information. setting the vdi_mode bit 7 activates an fgpi_data stream pre-processor that extracts the sav/eav sync signals (as de?ed in the video ccir 656 standard) out of an 8-bit d1 stream and generates the fgpi_start (fgpi_rec_start) and fgpi_stop (fgpi_buf_start) control signals. fgpi and input router setup requirements: the 8-bit data stream must be applied to the fgpi_data[7:0] pins vdi_mode[7] = 1, vdi_mode[4:3] = xx (don? care), vdi_mode[1:0] = 01 fgpi_ctl_mode = 0 (record mode) fgpi_ctl_sample_size = 00 (8-bit samples packed 4 samples per 32-bit word)
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-17 fgpi_ctl_buf_sync = 010 (switch buffers on alternating edges on fgpi_buf_start) fgpi_ctl_rec_sync = 01 (start record on falling edge on fgpi_rec_start)
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-18 4. register descriptions 4.1 mode registers table 2: register summary offset name clock domain description 0x07,0000 fgpi_ctl fgpi controls operational mode and enables/disables dma transfers 0x07,0004 fgpi_base1 mmio starting address for ?st buffer 0x07,0008 fgpi_base2 mmio starting address for second buffer 0x07,000c fgpi_size fgpi number of records/messages per buffer 0x07,0010 fgpi_rec_size fgpi size of record/message in samples 0x07,0014 fgpi_stride fgpi address stride between records/messages 0x07,0018 fgpi_nrec1 mmio number of records/messages transferred into buffer 1 0x07,001c fgpi_nrec2 mmio number of records/messages transferred into buffer 2 0x07,0020 fgpi_thresh1 fgpi interrupt threshold for buffer 1 0x07,0024 fgpi_thresh2 fgpi interrupt threshold for buffer 2 0x07,0028 - 0x07,0fdc reserved n/a 0x07,0fe0 fgpi_ir_status mmio module interrupt status 0x07,0fe4 fgpi_ir_ena mmio module interrupt enables 0x07,0fe8 fgpi_ir_clr mmio module interrupt clear (interrupt acknowledge) 0x07,0fec fgpi_ir_set mmio module interrupt set (debug) 0x07,0ff0 fgpi_soft_rst mmio module software reset 0x07,0ff4 fgpi_if_dis mmio module interface disable 0x07,0ff8 fgpi_mod_id_ext mmio module id extension 0x07,0ffc fgpi_mod_id mmio module id table 3: fast general purpose input (fgpi) bit symbol acces s value description fpgi registers offset 0x07,0000 fgpi_ctl 31:15 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 14 polarity_clk r/w 0 externally selects active clock edge for clk_fgpi via fgpi_clk_pol 0 = rising edge 1 = falling edge note: this bit not used in the pnx15xx series. all fgpi clock control is in the clock module. 13 capture_enable_2 r/w 0 enable input capture into buffer 2. this bit, along with bit 12 below, start and stop fgpi dma activity.
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-19 12 capture_enable_1 r/w 0 enable input capture into buffer 1. this bit, along with bit 13 above, start and stop fgpi dma activity. if input capture into only one buffer is desired, this bit must be used to start/stop dma. 11 mode r/w 0 0 = record/raw capture mode 1 = message capture mode 10 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 9:8 sample_size r/w 00 encodes size of data samples input on fgpi_data: 00 = 8-bit data samples 01 = 16-bit data samples 10 = 32-bit data samples 11 = same as 10 above 7:5 buf_sync / msg_stop r/w 000 encodes function of fgpi_stop / fgpi_buf_start pin record mode (fgpi_buf_start): 000 = switch buffers on rising edge on fgpi_buf_start. wait for next rising edge on fgpi_buf_start to start ?st buffer. 001 = switch buffers on falling edge on fgpi_buf_start. wait for next falling edge on fgpi_buf_start to start ?st buffer. 010 = switch buffers on alternating edges on fgpi_buf_start. wait for next rising edge on fgpi_buf_start to start ?st buffer. 011 = switch buffers on alternating edges on fgpi_buf_start. wait for next falling edge on fgpi_buf_start to start ?st buffer. 100 = no buffer sync. switch to alternate buffer at current buffer e nd- o f- b uffer (eob). start ?st buffer immediately after enable. 101 - 111 = same as 100 above. message mode (fgpi_stop): 000 = stop message on rising edge of fgpi_stop 001 = stop message on falling edge of fgpi_stop 010 , 100 , and 110 = same as 000 above. 011 , 101 , and 111 = same as 001 above. 4 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. table 3: fast general purpose input (fgpi) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-20 3:2 rec_start / msg_start r/w 00 encodes function of fgpi_start / fgpi_rec_start pin record mode (fgpi_rec_start): 00 = start record on rising edge on fgpi_rec_start 01 = start record on falling edge on fgpi_rec_start 10 = no record sync. switch to next record if current buffer is full. start ?st record immediately after enable. 11 = same as 10 above message mode (fgpi_start): 00 = start message on rising edge of fgpi_start 01 = start message on falling edge of fgpi_start 10 = same as 00 above. 11 = same as 01 above. 1 tstamp_select r/w 0 1 = write timestamp before record/message data. timestamp is a 4-byte time-of-arrival for fgpi_rec_start / fgpi_start event. if this bit and bit-0 below (var_length) are both set the timestamp is written before the length. note : the length of the timestamp (4 bytes) is not included in the record/message size in fgpi_size register but is included in the stride (fgpi_stride register). 0 var_length r/w 0 1 = the length of each record/message (in samples) is written before record/message data. var_length is a 4-byte count. if this bit and bit-1 above (tstamp_select) are both set the timestamp is written before the length. note : the length of var_length (4 bytes) is not included in the record/message size in fgpi_size register but is included in the stride (fgpi_stride register). offset 0x07,0004 fgpi_base1 31:2 base1 r/w 0 32-bit word aligned address pointing to buffer 1 base. 1:0 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. offset 0x07,0008 fgpi_base2 31:2 base2 r/w 0 32-bit word aligned address pointing to buffer 2 base. 1:0 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. table 3: fast general purpose input (fgpi) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-21 4.2 status registers offset 0x07,000c fgpi_size 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 size r/w 0 number of records/messages per buffer. range: 1 to 2 24 -1 offset 0x07,0010 fgpi_rec_size 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 rec_size r/w 0 number of samples per record/message. range: 2 to 2 24 -1 (see section 3.2.1 on page 14- 14 on minimum rec_size) offset 0x07,0014 fgpi_stride 31:2 stride r/w 0 address stride between records/messages 1:0 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. offset 0x07,0018 fgpi_nrec1 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 nrec1 r 0 number of records/messages sent to buffer 1. cleared to zero when fgpi_base1 register is written to. offset 0x07,001c fgpi_nrec2 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 nrec2 r 0 number of records/messages sent to buffer 2. cleared to zero when fgpi_base1 register is written to. offset 0x07,0020 fgpi_thresh1 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 thresh1 r/w 0 thresh1_reached interrupt generated when fgpi_nrec1 count equals this register value. range: 1 to 2 24 -1 offset 0x07,0024 fgpi_thresh2 31:24 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 23:0 thresh2 r/w 0 thresh2_reached interrupt generated when fgpi_nrec2 count equals this register value. range: 1 to 2 24 -1 table 3: fast general purpose input (fgpi) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-22 table 4: status registers bit symbol acces s value description standard registers offset 0x07,0fe0 fgpi_ir_status 31:8 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 7 buf1_active r 0 1 when buffer 1 is active 6 overflow r 0 message over?w error detected. 5 mbe r 0 memory bandwidth error detected. 4 underrun r 0 buffer underrun detected. 3 thresh2_reached r 0 buffer 2 threshold reached. 2 thresh1_reached r 0 buffer 1 threshold reached. 1 buf2_full r 0 buffer 2 is full. 0 buf1_full r 0 buffer 1 is full. offset 0x07,0fe4 fgpi_ir_ena 31:7 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 overflow_ena r/w 0 message over?w error interrupt enable 5 mbe_ena r/w 0 memory bandwidth error interrupt enable 4 underrun_ena r/w 0 buffer underrun interrupt enable 3 thresh2_reached_ ena r/w 0 buffer 2 threshold interrupt enable 2 thresh1_reached_ ena r/w 0 buffer 2 threshold interrupt enable 1 buf2_full_ena r/w 0 buffer 2 full interrupt enable 0 buf1_full_ena r/w 0 buffer 1 full interrupt enable offset 0x07,0fe8 fgpi_ir_clr 31:7 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 overflow_ack r/w 0 message over?w error interrupt acknowledge 5 mbe_ack r/w 0 memory bandwidth error interrupt acknowledge 4 underrun_ack r/w 0 buffer underrun interrupt acknowledge 3 thresh2_reached_ ack r/w 0 buffer 2 threshold interrupt acknowledge 2 thresh1_reached_ ack r/w 0 buffer 2 threshold interrupt acknowledge 1 buf2_done_ack r/w 0 buffer 2 done interrupt acknowledge 0 buf1_done_ack r/w 0 buffer 1 done interrupt acknowledge offset 0x07,0fec fgpi_ir_set 31:7 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 6 overflow_set r/w 0 set message over?w error interrupt
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-23 5 mbe_set r/w 0 set memory bandwidth error interrupt 4 underrun_set r/w 0 set buffer underrun interrupt 3 thresh2_reached_ set r/w 0 set buffer 2 threshold interrupt 2 thresh1_reached_ set r/w 0 set buffer 2 threshold interrupt 1 buf2_done_set r/w 0 set buffer 2 done interrupt 0 buf1_done_set r/w 0 set buffer 1 done interrupt offset 0x07,0ff0 fgpi_soft_rst 31:1 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 software_reset r/w 0 1 = asserts an internal fgpi reset (also output on fgpi_resetn pin) the effects are: all fgpi registers are reset all pending interrupts are removed any pending dma writes are aborted (fifos are cleared) all state machines return to their reset state all clocks must be running before the soft reset can complete. this bit will clear after the reset completes. offset 0x07,0ff4 fgpi_if_dis 31:1 reserved r 0 to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 disable_bus_if r/w 0 1 = all writes to fgpi mmio space (except this register) will be ignored. all reads (except this register) will return 0x00000000. the fgpi module clock can be stopped low to save power when this bit is set. offset 0x07,0ff8 fgpi_mod_id_ext 31:0 module_id_ext r 0 32-bit module id extension offset 0x07,0ffc fgpi_mod_id 31:16 mod_id r 0x014b 16-bit module id code 15:12 major_rev r 0 4-bit major revision code 11:8 minor_rev r 0x1 4-bit minor revision code 7:0 aperature r 0 8-bit aperture code. 0x00 = 4k byte aperture table 4: status registers bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 14: fgpi: fast general purpose interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 14-24
1. introduction the audio output module provides a dma-driven serial interface designed to support stereo audio d/a converters. the audio out module can support up to eight pcm audio channels by driving up to four external stereo d/a converters. the audio out unit provides a glueless interface to high quality, low cost oversampling d/a converters. a precise programmable oversampling clock is featured. 1.1 features the audio out unit, along with the associated external d/a converters, provides the following capabilities: up to 8 channels of audio output 16-bit or 32-bit samples per channel programmable 1 hz to 100 khz sampling rate (note: this is a practical range. the actual sample rate is application dependent.) internal or external bit clock source autonomously retrieves processed audio data from dual dma buffers in memory 16-bit mono and stereo pc standard memory data formats control capability for highly integrated pc codecs remark: ac-97 codecs are not supported. 2. functional description the audio out module has four major subsystems: a programmable sample clock generator, a dma engine, a parallel to serial converter and memory mapped registers for con?uration and control. the audio out connectors provide the digital audio stream, clock and control signals to external d/a converters. a block diagram of audio out is illustrated in figure 1 . the dma engine reads 16 or 32-bit samples from memory using dual dma buffers in memory. software initially assigns two full sample buffers in memory containing an integral number of samples for all active channels. the dma engine retrieves samples from the ?st buffer in memory until exhausted and continues from the chapter 15: audio output pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-2 second buffer in memory as a request for a new ?st sample buffer in memory is issued to the system controller. this action is repeated as the buffers in memory are sent out. the samples are given to the data serializer (parallel-to-serial converter), which sends them out in a msb ?st or lsb ?st serial frame format that can also contain one or two codec control words of up to 16 bits. the output frame structure is programmable. 2.1 external interface the audio out module has seven signals connected to the external world: ao_osclk referenced as osclk in this chapter. ao_sck referenced as sck in this chapter. ao_ws referenced as ws in this chapter. ao_sd[3:0] referenced as sd[3:0] in this chapter. figure 1: audio out block diagram clock divider/generator parallel to serial converter mmio registers & logic dtl dma interface logic osclk sck ws sck divider ws divider divider value divider value sd[0] sd[1] sd[2] sd[3] shift register shift register shift register shift register parallel framing/sample options dtl interface dtl interface data external interface dcs bus serial clock
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-3 the osclk output is an accurate, programmable clock output intended to be used as the master system clock for the external d/a subsystem. the other pins constitute a ?xible serial output interface. sck - serial clock ws - word select 0 = left channel 1 = right channel sd[3:0] - serial data using the audio out mmio registers, these connectors can be con?ured to operate in a variety of serial interface framing modes, including but not limited to: standard stereo i 2 s (msb ?st, one bit delay from ws, left and right data in a frame). for further details on i 2 s, refer to the ? 2 s bus speci?ation dated june 5 1996, in the multimedia ics data handbook ic22 by philips semiconductors, 1998. lsb ?st with 1- to 16-bit data per channel table 1: audio out unit external signals [1] signal name type description ao_osclk out oversampling clock . this output can be programmed to emit any frequency up to 40 mhz. it is intended for use as the 256 fs or 384 fs oversampling clock by the external d/a conversion subsystem. ao_sck i/o serial clock . when audio out is programmed to act as the serial interface timing slave (reset default), sck acts as input. it receives the serial clock from the external audio d/a subsystem. the clock is treated as fully asynchronous to the chip main clock. when audio out is programmed to act as serial interface timing master, sck acts as output. it drives the serial clock for the external audio d/a subsystem. the clock frequency is a programmable integral divide of the osclk frequency. sck is limited to the frequency of the osclk or lower. ao_ws i/o word select . when audio out is programmed as the serial-interface timing slave (reset default), ws acts as an input. ws is sampled on the opposite sck edge at which sd is asserted. when audio out is programmed as serial-interface timing master, ws acts as an output. ws is asserted on the same sck edge as sd. ws is the word select or frame synchronization signal from/to the external d/a subsystem. each audio channel receives one sample for every ws period. ws can be set to change on osclk positive or negative edges by the clock_edge bit. ao_sd[0] out serial data for channel 1 . connect to stereo external audio d/a subsystem. sd[0] can be set to change on osclk positive or negative edges by the clock_edge bit. ao_sd[1] out serial data for channel 2 . connect to stereo external audio d/a subsystem. sd[1] can be set to change on osclk positive or negative edges by the clock_edge bit. ao_sd[2] out serial data for channel 3 . connect to stereo external audio d/a subsystem. sd[2] can be set to change on osclk positive or negative edges by the clock_edge bit. ao_sd[3] out serial data for channel 4 . connect to stereo external audio d/a subsystem. sd[3] can be set to change on osclk positive or negative edges by the clock_edge bit. [1] these signals are external to the chip, after the pad cells.
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-4 complex serial frames of up to 512 bits/frame 2.2 memory data formats the audio out unit autonomously obtains samples from memory in 16 or 32-bit per sample memory formats, as shown in figure 2 . successive samples are always read from increasing memory address locations. the audio out implements a double buffering scheme in memory to ensure that there are always samples available to transmit, even if the system controller is highly loaded and slow to respond to interrupts. the software assigns two equal size buffers in memory by writing 2 base addresses and a sample size to the corresponding mmio registers described in section 4. on page 15- 15 . prior to output transmission, if sign_convert = 1, the msb of the memory data is inverted. this allows the use of external twos complement 16-bit d/a converters to generate audio from 16-bit unsigned samples. this msb inversion also applies to the ??values transmitted to non-active output channels. note that the audio out hardware does not support a-law or m-law data formats. if such formats are desired, the system dsp processor should be used to convert from a-law or m-law data to 16-bit linear data. 2.2.1 endian control audio out expects data to be supplied in little endian byte ordering mode. in little endian byte ordering mode, the least signi?ant byte has the lowest memory address. figure 2: examples of audio out memory dma formats 16 bit, stereo, nr_chan=00 16 bit, stereo, nr_chan=10 32 bit, stereo, nr_chan=00 adr sd[0].left n adr sd[0].left n adr sd[0].left n adr+2 sd[0].right n+1 adr+2 sd[0].right n adr+4 sd[0].left n+1 adr+4 sd[1].left n adr+4 sd[0].right n adr+6 sd[0].right n+1 adr+6 sd[1].right n adr+8 sd[0].left n+2 adr+8 sd[2].left n adr+10 sd[0].right n+2 adr+10 sd[2].right n adr+8 sd[0].left n+1 adr+12 adr+14 sd[0].left n+3 sd[0].right n+3 adr+12 adr+14 sd[0].left n+1 sd[0].right n+1 adr+12 sd[0].right n+1 table 2: operating modes and memory formats nr_chan mode destination of successive samples 00 mono sd[0].left 00 stereo sd[0].left, sd[0].right 01 mono sd[0].left, sd[1].left 01 stereo sd[0].left, sd[0].right, sd[1].left, sd[1].right 10 mono sd[0].left, sd[1].left, sd[2].left 10 stereo sd[0].left, sd[0].right, sd[1].left, sd[1].right, sd[2].left, sd[2].right 11 mono sd[0].left, sd[1].left, sd[2].left, sd[3].left 11 stereo sd[0].left, sd[0].right, sd[1].left, sd[1].right, sd[2].left, sd[2].right, sd[3].left, sd[3].right.
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-5 2.3 audio out data dma operation upon reset, transmission is disabled (trans_enable = 0), and buffer 1 in memory is the active buffer (buf1_active = 1). the system software initiates transmission by providing two equal size buffers in memory (?led with valid audio data) and putting the base addresses and sample size in the two ao_base x registers and the ao_size register. once two valid buffers are assigned, transmission can be enabled by writing a ??to trans_enable. note that serial frame con?urations should not be changed when transmission is enabled. the audio out unit hardware now proceeds to empty buffer 1 in memory by transmission of output samples. the buffers in memory are requested in blocks of up to 1024 32-bit word maximums. when buffer 1 in memory is empty, buf1_empty is asserted, and transmission continues without interruption from buffer 2 in memory. if buf1_inten is enabled, a level triggered system interrupt request is generated. note that the buffers in memory must be 64-byte aligned (the six lsbs of ao_base1 and ao_base2 are zero). memory buffer sizes must be in multiples of 64 samples (the six lsbs of ao_size are zero). the system software is required to assign a new, full buffer to ao_base1 and perform an ack1 before buffer 2 in memory is empty. transmission continues from buffer 2 in memory until it is empty. at that time, buf2_empty is asserted, and transmission continues from the new buffer 1 in memory. an ack x by the interrupt service routine performs two functions: it noti?s audio out that the corresponding ao_base x register now points to a buffer ?led with samples. it clears buf x _empty. upon receipt of an ack x , the audio out hardware de asserts the interrupt request line at the next system controller clock edge. 2.3.1 trans_enable the trans_enable bit of the ao_ctl register controls the transfer of data from memory and the transmission of data from the serial output pins. while this control bit is enabled, con?uration parameters in the register set should not be changed. when trans_enable is disabled after it had been enabled, an abort is sent out to the dma interface adapter to cancel all dma transactions associated with the audio out and serial transmission as well as ws transmission is stopped. before enabling the trans_enable bit after an enable, disable sequence, care must be taken that the correct address values are stored in the base address registers. upon a restart of trans_enable, dma transfers will start from the address given by ao_base1. in some modes, a restart of existing values of the base address registers may not produce coherent results. when trans_enable is disabled after a period of being enabled, the status ?gs for buf1_active, underrun, hbe, buf2_empty and buf1_empty within the ao_status register will retain the values they were at when the disable effect took place. if the trans_enable is enabled once again, these ?gs will be reset to their initial states by the hardware before starting up transmission again.
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-6 2.4 interrupts audio out has a level triggered interrupt request signal. an interrupt is asserted as long as any of the underrun, hbe, buf1_empty or buf2_empty condition ?gs are asserted. and the corresponding inten bit is enabled. interrupts are sticky (i.e., an interrupt remains asserted until the software explicitly clears the condition ?g by an ack action). remark: for legacy reasons, the mmio interrupt mechanism for audio out has not been changed. 2.4.1 interrupt latency during normal error free transmission, the source of an audio out interrupt will be from buf1_empty and buf2_empty. the dma buffer size con?ured in the ao_size register will directly affect the frequency of these ?mpty?interrupts. software should set up the ao_size register with a large enough value so that interrupts occur no more frequently than 1 ms in order to meet system interrupt latency requirements. 2.5 timestamp events audio out exports event signals associated with audio transmission to the central timestamp/timer function in the system. the central timestamp/timer function can be used to count the number of occurrences of each event or timestamp, the occurrence of the event, or both. the event will be a positive edge pulse with the duration of the event to be greater than or equal to 200 ns. the speci? event exported is: buf_done the occurrence of this tstamp event indicates that the last word of the current dma memory buffer has started to be sent out on the serial data port. this event represents a precise, periodic time interval which can be used by system software for audio/video synchronization. 2.6 serial data framing the audio out unit can generate data in a wide variety of serial data framing conventions. figure 3 illustrates the notion of a serial frame. if polarity = 1, a frame starts with a positive edge of the ws signal. if polarity = 0, a serial frame starts with a negative edge on ws. (see section 4. on page 15- 15 .) if
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-7 clock_edge = 0, the parallel-to-serial converter samples ws on a positive clock edge transition and outputs the ?st bit (bit 0) of a serial frame on the next falling edge of sck. if clock_edge = 1, the parallel-to-serial converter samples ws on the negative edge of sck, while audio data is output on the positive edge. that is, the sck polarity would be reversed with respect to figure 3 . every serial frame transmits a single left and right channel sample and optional codec control data to each d/a converter. the sample data can be in an lsb ?st or msb ?st form at an arbitrary serial frame bit position and with an arbitrary length. (see section 4. .) in msb ?st mode (datamode = 0), the parallel-to-serial converter sends the value of left[msb] in bit position leftpos in the serial frame. subsequently, bits from decreasing bit positions in the left dataword, up to and including left[sspos], are transmitted in order. in lsb ?st mode (datamode = 1), the parallel-to-serial converter sends the value of left[sspos] in bit position leftpos in the serial frame. subsequent bits from the left data word, up to and including left[msb], are transmitted in order. the exact bits transmitted for a data item ??are shown in t ab le 3 . frame bits that do not belong to either left[msb:sspos] or right[msb:sspos] or a codec control ?ld ( section 2.7 on page 15- 9 ) are shifted out as zero. this zero extension ensures that audio out can be used in combination with d/a converters which expect more bits than the actual number of transmitted bits in the current operating mode (e.g., 18-bit d/as operating with 16-bit memory data). if a starting position for a ?ld is de?ed at a position such that the end of a serial frame is reached before the end of the data ?ld is reached, the data beyond the last bit of the serial frame is truncated. figure 3: de?ition of serial frame bit positions (polarity = 1, clock_edge = 0) sck ws sd frame n-1 30 31 01 2 345 678 9 10 11 12 13 14 15 16 17 frame n 18 19 20 21 22 23 24 25 26 27 28 29 30 31 0 1 23 456 7 frame n+1 table 3: bits transmitted for each memory data item operating mode first bit last bit valid sspos values 16 bit/sample, msb ?st s[15] s[sspos] 0...15 16 bit/sample, lsb ?st s[sspos] s[15] 0...15 32 bit/sample, msb ?st s[31] s[sspos] 0...31 32 bit/sample, lsb ?st s[sspos] s[31] 0...31
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-8 2.6.1 serial frame limitations due to the implementation, there is a minimum serial frame length requirement that is operating-mode dependent according to t ab le 4 . 2.6.2 ws characteristics the ws signal is used to de?e the start point of a serial frame. the start of a frame can be marked by a transition on ws 1 clock before the start of the ?st bit of a new frame. this ws transition can be programmed to be either a positive or a negative edge transition. in addition, the ws signal can be programmed to be a 50% duty cycle wave form or a pulse that is 1 clock cycle wide. if the ws is con?ured to be 1 single clock wide pulse, the pulse spans the 2 clock cycles preceding the ?st bit of the new frame. if the ws is con?ured to be a 50% duty cycle waveform, the active edge of the ws signal occurs 1 clock cycle before the ?st bit of the new frame. if the serial frame is of an even bit count, then the second transition of the ws signal occurs in the clock cycle before the halfway point of the serial frame. if the serial frame is of an odd bit count, then the portion of the ws wave that is in the low state has the extra clock cycle. with an odd bit count for a serial frame and with a frame starting with a negative edge of the ws, a 50% duty cycle ws signal would have the ?st part of the ws signal 1 clock longer than the second half. with a positive edge of the ws signal marking the start of a serial frame, the second half of the serial frame would have a ws signal longer by 1 clock cycle. 2.6.3 i 2 s serial framing example figure 4 and t ab le 5 show how the audio out module mmio registers should be set to transmit 16 or 32 bits of stereo data via an i 2 s serial standard to an 18-bit d/a converter with a 64-bit serial frame. table 4: minimum serial frame length in bits operating mode minimum serial frame length 16 bit/sample, mono 13 bits 32 bit/sample, mono 13 bits 16 bit/sample, stereo 13 bits 32 bit/sample, stereo 36 bits figure 4: serial frame (64 bits) of a 18-bit precision i 2 s d/a converter 52 sck ws sdx left channel data n ( 18) right channel data n (18) left channel data n+1 (18) 123 1718 30313233 49 50 51 62 63 0 1 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-9 remark: the transfer of data from sdram into the audio out module's transmit fifos is initiated by the transition of ws, not by transmit enable. as a consequence, there is a delay between the receipt of the first ws pulse and the transmission of the first data. the length of this delay is dependent on system load and is not easily predictable. 2.7 codec control in addition to the left and right data ?lds that are generated based on autonomous dma action, a serial frame generated by audio out can be set to contain one or two control ?lds of up to 16 bits in length. each control ?ld can be independently enabled or disabled by the cc1_en, cc2_en bits in ao_ctl. the content shifted into the frame is taken from the cc1 and cc2 ?ld in the ao_cc register. the cc1_pos and cc2_pos ?lds in the ao_cfc register determine the ?st bit position in the frame where the control ?ld is emitted observing the setting of datamode (i.e., lsb or msb ?st). the cc_busy bit in ao_status indicates if the audio out unit is ready to receive another cc1, cc2 value pair. writing a new value pair to ao_cc writes the value into a buffer register and raises the cc_busy status. (see section 4. on page 15- 15 .) as soon as both cc1 and cc2 values have been copied to a shadow register in preparation for transmission, cc_busy is negated, indicating that the audio out logic is ready to accept a new codec control pair. the old cc1/cc2 data is transmitted continuously (i.e., software is not required to provide new cc1 and cc2 data). software must ensure that the cc_busy status is negated before writing a new cc1, cc2 pair. the user, by the process of waiting on cc_busy, can reliably emit a sequence of individual audio frames with distinct control ?ld values. this can, for example, be used during codec initialization. note that no provision is made for interrupt-driven operation of such a sequence of control values. it is assumed, after initialization, that the value of control ?lds determines slowly changing, asynchronous parameters such as output volume. table 5: example setup for 64-bit i 2 s framing field value explanation polarity 0 frame starts with negative edge audio out ws. leftpos 0 left[msb] will go to serial frame position 0. rightpos 32 right[msb] will go to serial frame position 32. datamode 0 msb ?st. sspos 0 stop with left/right[0], send 0s after. (for 32-bit/sample mode, this ?ld could be set to 14 to ensure zeroes in all unused bit positions.) clock_edge 0 audio out sd change on negative edge audio out sck wsdiv 63 serial frame length = 64 ws_pulse 0 emit 50% duty cycle audio out ws.
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-10 it is legal to program the control ?ld positions within the frame such that cc1 and cc2 overlap each other and/or left and right data ?lds. if two ?lds are de?ed to start at the same bit position, the priority is left (highest), right, cc1 then cc2. the ?ld with the highest priority will be emitted starting at the con?cting bit position. if a ?ld f2 is de?ed to start at a bit position i that falls within a ?ld f1 starting at a lower bit position, f2 will be emitted starting from i and the rest of f1 will be lost. any bit positions not belonging to a data or control ?ld will be emitted as zero. if a ?ld is de?ed to start at a bit position such that the end of the ?ld goes beyond the end of the frame, the data beyond the end of the frame (as de?ed by the active edge of ws) is lost. figure 5 shows a 64-bit frame suitable for use with the cs4218 codec. it is obtained by setting polarity=1, leftpos=0, rightpos=32, datamode=0, sspos=0, clock_edge=1, ws_pulse=1, cc1_pos= 16, cc1_en=1, cc2_pos=48 and cc2_en=1. note that frames are generated (externally or internally) even when trans_enable is de-asserted. writes to cc1 and cc2 should only be done after trans_enable is asserted. the rst cc values will then go out on the next frame. 2.8 data bus latency and hbe the audio out unit relies on the fifo buffers within the dma interface adapter as well as an output holding register that holds a single mono sample or single stereo sample pair. for audio out there are four separate stereo output channels and each output channel has one output holding register. the holding register width is 64 bits. under normal operation, the dma interface adapter provides samples from memory fast enough to avoid any missing samples. meanwhile, data is being emitted from one 64-byte hardware buffer and holding register. if the data bus arbiter is set up with an insuf?ient latency guarantee, the situation can arise that the hardware fifo buffer within the dma interface adapter is not re?led in time and the buffer and holding register are exhausted by the time a new output sample is due. in that case the hbe ?g is raised to indicate a bandwidth error. the last sample for each channel will be repeated until the buffer is refreshed. the hbe condition is sticky and can only be cleared by an explicit ack_hbe. this condition indicates an incorrect setting of the data bus bandwidth arbiter. t ab le 6 shows the maximum tolerable latency for a number of common operating modes. the right most column in the table indicates the maximum tolerable latency for audio out under normal operating condition. to sustain error free audio playback, one 64-byte dma transfer must be completed within the maximum latency period figure 5: example codec frame layout for a crystal semiconductor cs4218 sck ws sdx 0 1 2 3 15 16 31 32 47 48 62 63 0 1 left data n +1(16 ) lsb cc2(16) lsb right channel data n (16) lsb cc1(16) lsb left channel datan (16)
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-11 indicated for each operating mode. note that for high sample rates with more than four channels (96 khz, 32-bit, >4ch), audio out cannot guarantee error-free operation due to data bus latency restrictions. 2.9 error behavior in normal operation, the system controller and audio out hardware continuously exchange buffers without ever failing to transmit a sample. if the system controller fails to provide a new dma buffer address in time, the underrun error ?g is raised and the last valid sample or sample pair is repeated until a new buffer of data is assigned by an ack1 or ack2. the underrun ?g is not affected by ack1 or ack2; it can only be cleared by an explicit ack_udr. table 6: audio out latency tolerance examples transfer mode fs (khz) t (nsec) * max latency (usec) (with t=1/fs) 2 ch stereo 16 bit/sample 48.0 20833 354.17 4 ch stereo 16 bit/sample 48.0 20833 187.50 6 ch stereo 16 bit/sample 48.0 20833 104.17 8 ch stereo 16 bit/sample 48.0 20833 104.17 2 ch stereo 32 bit/sample 48.0 20833 187.50 4 ch stereo 32 bit/sample 48.0 20833 104.17 6 ch stereo 32 bit/sample 48.0 20833 62.50 8 ch stereo 32 bit/sample 48.0 20833 62.50 2 ch stereo 16 bit/sample 96.0 10417 177.08 4 ch stereo 16 bit/sample 96.0 10417 93.75 6 ch stereo 16 bit/sample 96.0 10417 52.08 8 ch stereo 16 bit/sample 96.0 10417 52.08 2 ch stereo 32 bit/sample 96.0 10417 93.75 4 ch stereo 32 bit/sample 96.0 10417 52.08 * max latency (usec) (with t=1/fs) 2ch 16it stereo: (17 * t)2ch 32bit stereo:(9 * t) 4ch 16bit stereo:(9 * t)4ch 32bit stereo:(5 * t) 6ch 16bit stereo: (5 * t)6ch 32bit stereo:(3 * t) 8ch 16bit stereo:(5 * t)8ch 32bit stereo:(3 * t)
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-12 if an hbe error occurs, the last valid sample or sample pair is repeated until the audio out hardware receives enough data to generate a new serial data frame from the dma interface adapter. 3. operation 3.1 clock programming 3.1.1 sample clock generator the sample clock generator is programmable to support various sample frequencies. figure 6 illustrates the different clock capabilities of the audio out unit. a square wave direct digital synthesizer (dds) drives the clock system. this dds is external to the audio out block. using the dds as a clock source allows software to control the coarse and ?e clock rate so that complex forms of synchronization can be implemented without external hardware. examples include locking the audio to a broadcast clock, or locking it to an spdif input without changing the system's hardware. the dds output is always sent to the osclk output pin. this output is intended to be used as the 256 fs or 384 fs system clock source for oversampling d/a converters. software may change the oversampling clock frequency dynamically (via the dds controls) to adjust the outgoing audio sample rate. in atsc transport stream decoding, this is the method used by which the system software locks the audio output sample rate to the original program provider sample rate. figure 6: audio out clock system and i/o interface osclk sck ws sd[0] sd[1] sd[2] sd[3] (e.g. 256 x fs) (e.g. 64 x fs) parallel to serial left sample right sample ao_cc[31:0] audio out domain ser_master div n+1 div n+1 wsdiv sckdiv square wave 27 mhz x 64 dds converter 32 16 or 32 16 or 32 80 70 dds from clocks modul e
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-13 t ab le 7 presents several sample rates with the sckdiv setting necessary to achieve a bit clock of 64 fs. the values of sckdiv given assume the oversampling clock supplied to audio out is either 256 fs or 384 fs. the value of sckdiv is determined by equation 11 . (11) remark: sckdiv is in the range of 0-255. 3.1.2 clock system operation word select (ws) and serial clock (sck) are sent to the external d/a converter in the master mode. ws determines the sample rate: each active channel receives one sample for each ws period. sck is the data bit clock. the number of sck clocks in a ws period is the number of data bits in a serial frame required by the attached d/a converter. ws is derived from the sck bit clock. it is controlled by the value of wsdiv and it sets the serial frame length. the number of bits per frame is equal to wsdiv+1. there are some minimum length requirements for a serial frame. refer to section 2.6.1 on page 15- 8 for details. sck and ws can be con?ured as input or output by the ser_master control ?ld in the ao_serial register. if con?ured as an output, sck can be set to a divider of the osclk output frequency. (see section 4. on page 15- 15 for more details.) whether set as input or output, the sck connector is always used as the bit clock for parallel to serial conversion. the ws signal always acts as the trigger to start the generation of a serial frame. ws can also be programmed using wsdiv to control the serial frame length. the number of bits per frame is equal to wsdiv+1. if the serial frame length is set to be an odd number of bits and the ws pulse is programmed to be 50% duty cycle, the portion of the ws waveform that is in the low state will have the extra clock bit. the preferred con?uration of the clock system options is to use osclk as the d/a subsystem master clock and let the d/a subsystem be a timing slave to the serial interface (ser_master = 1). some d/a converters provide somewhat better snr properties if they are con?ured as serial masters, so the audio out should be con?ured as a slave in this case (ser_master = 0). as illustrated by figure 6 , the internal parallel to serial converter that constructs the serial frame is indifferent as to who is the serial master. table 7: clock system setting fs osclk sckdiv sck 44.1 khz 256 fs 3 64 fs 48.0 khz 256 fs 3 64 fs 44.1 khz 384 fs 5 64 fs 48.0 khz 384 fs 5 64 fs f sck f osclk sckdiv 1 + ------------------------------- --- =
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-14 3.2 reset-related issues audio out is reset by the system reset signal or by writing ao_ctl.reset = 1. either reset method sets all mmio ?lds to their default values as indicated in the section 4. register descr iptions . when software reset is activated (ao_ctl.reset = 1) the clock generation using the values programmed in the internal mmio register (ser_master, ao_serial, ...) is stopped since these values get reset. this causes the ao module to do not have a clock anymore which does not complete the reset. therefore before resetting the ao module, the ao module should be clocked by the crystal 27 mhz clock. software must follow a series of steps to ensure that software reset happens correctly: 1. check to see if there is a valid clock present on the audio out external clock input. 2. if there is no clock, then write to the clocks block to switch the audio out block clock input to the 27 mhz oscillator. 3. apply software reset and poll the reset bit until it is cleared. 4. program the clocks block to switch back to the external clock mode for the audio out block. clocks are required to be running during hw/sw reset because synchronous reset is used to initialize the logic. the unique feature with audio is that unlike all other blocks in the system, the audio blocks default to the external clock source on any reset. if the external clock does not exist when a hw reset is applied, then the logic is left uninitialized without any indication. 3.3 register programming guidelines when con?uring the audio out, data framing options and dma buffer parameters must be programmed before enabling transmission. 3.4 power management audio out has no internal powerdown functionality, however the chip power management software can remove the main block level clock to audio out. if the audio out module enters a powerdown state, sck, ws and sd[ x ] hold their value stable but osclk continues to provide a d/a converter oversampling clock. once the system wakes up, the signals resume their original transitions at the point where they were halted. the external d/a converter subsystem will most likely be confused by this behavior, so it is recommended that audio out transmissions be stopped (by deactivating trans_enable) prior to software enable of audio out powerdown.
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-15 4. register descriptions the following tables illustrate the register set of the audio out block. access to these registers is via the dtl port. these registers are distributed between the dtl clock domain (dcs/mmio bus), the dma clock domain (mtl/ddr bus) and the ip clock domain, i.e. the ao module clock. the access time to these registers is proportional to the clock domain frequency with respect to the cpu speed. 4.1 register summary 4.2 register table table 8: register summary offset name description 0x11 0000 ao_status provides status of buffers and other audio out components/situations. 0x11 0004 ao_ctl control register to con?ure audio out options 0x11 0008 ao_serial control register to con?ure audio out serial timing and data options 0x11 000c ao_framing control register to con?ure data framing 0x11 0010 reserved 0x11 0014 ao_base1 base address of dma buffer 1 in memory 0x11 0018 ao_base2 base address of dma buffer 2 in memory 0x11 001c ao_size the dma buffer size in samples 0x11 0020 ao_cc codec control data content 0x11 0024 ao_cfc codec data position 0x11 0028?ff0 reserved 0x11 0ff4 ao_pwr_dwn powerdown function 0x11 0ffc ao_module_id provides module id number, including major and minor revision levels. table 9: audio output port registers bit symbol acces s value description offset 0x11 0000 ao_status?tl clock domain 31:6 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . 5 cc_busy r 0 0 = audio out is ready to receive a cc1, cc2 pair. 1 = audio out is not ready to receive a cc1, cc2 pair. try again in a few sck clock intervals. 4 buf1_active r 1 1 =dma buffer 1 in memory will be used for the next sample to be transmitted. 0 =dma buffer 2 in memory will contain the next sample.
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-16 3 underrun r 0 an underrun error has occurred i.e., the system controller/ software failed to provide a full dma buffer in memory in time and no new samples were transmitted. the last sample or sample pairs were sent to the d/a converter. if udr_inten is also ?? an interrupt request is pending. the underrun ?g can only be cleared by writing an ??to ack_udr. 2 hbe r 0 bandwidth error indicates that no new data was transmitted due to an inability of the dma interface adapter to provide the required data in time for the start of a new frame. the last data set is repeated. if hbe_inten is an ?? then an interrupt is also sent to the system. the hbe ?g stays set until an ??is written to ack_hbe. 1 buf2_empty r 0 1= buffer 2 is empty. if buf2_inten is also ?? an interrupt request is asserted. buf2_empty is cleared by writing a ? to ack2, at which point the audio out hardware will assume that ao_base2 and ao_size describe a new full dma buffer in memory. 0 buf1_empty r 0 1= buffer 1 is empty. if buf1_inten is also ?? an interrupt request is asserted. buf1_empty is cleared by writing a ? to ack1, at which point the audio out hardware will assume that ao_base1 and ao_size describe a new full dma buffer in memory. offset 0x11 0004 ao_ctl?tl clock domain 31 reset r/w 0 resets the audio out logic. see section 3.2 on page 15- 14 for a description of software reset. 30 trans_enable r/w 0 transmission enable ?g 0 = audio out is inactive. 1 = audio out transmits samples and acts as dma master to read samples from local memory. do not change any of the framing con?urations while transmission is enabled. 29:28 trans_mode r/w 00 00 = mono, 32 bits/sample. left and right data sent to each active output are the same. 01 = stereo, 32 bits/sample 10 = mono, 16 bits/sample. left and right data are the same. 11 = stereo, 16 bits/sample 27 sign_convert r/w 0 0 =leave msb unchanged. 1 = invert msb (not applied to codec control ?lds). 26:25 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read 24 cc1_en r/w 0 0 = cc1 emission disabled. 1 = cc1 emission enabled. 23 cc2_en r/w 0 0 = cc2 emission disabled. 1 = cc2 emission enabled. 22 ws_pulse r/w 0 0 = emit 50% ws. 1 = emit single sck cycle ws. table 9: audio output port registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-17 21:8 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read 7 udr_inten r/w 0 underrun interrupt enable. 0 = no interrupt for underrun condition 1 = interrupt if an underrun error occurs. 6 hbe_inten r/w 0 hbe interrupt enable: 0 = no interrupt for hbe condition 1 = interrupt if a data bus bandwidth error occurs. 5 buf2_inten r/w 0 buffer 2 empty interrupt enable: 0 = no interrupt when dma buffer is empty. 1 = interrupt if dma buffer 2 in memory is empty. 4 buf1_inten r/w 0 buffer 1 empty interrupt enable: 0 = no interrupt when dma buffer 1 is empty. 1 = interrupt if dma buffer 1 in memory is empty. 3 ack_udr r/w 0 write a 1 to clear the underrun ?g and remove any pending underrun interrupt request. ack_udr always reads 0. 2 ack_hbe r/w 0 write a 1 to clear the hbe ?g and remove any pending hbe interrupt request. ack_hbe always reads as 0. 1 ack2 r/w 0 write a 1 to clear the buf2_empty?g and remove any pending buf2_empty interrupt request. ao_base2 is then used to fetch buffer1 data from memory. ack2 always reads 0. 0 ack1 r/w 0 write a 1 to clear the buf1_empty ?g and remove any pending buf1_empty interrupt request. ao_base1 is then used to fetch buffer1 data from memory. ack1 always reads 0. offset 0x11 0008 ao_serial?tl clock domain 31 ser_master r/w 0 0 = the d/a subsystem is the timing master over the audio out serial interface. sck and ws act as inputs. 1 = ao is the timing master over serial interface. sck and ws act as outputs. this mode is required for 4, 6 or 8 channel operation. the ser_master bit should only be changed while audio out is disabled i.e.,trans_enable = 0. 30 datamode r/w 0 0 = data is transmitted msb ?st. 1 = data is transmitted lsb ?st. 29 clock_edge r/w 0 0 = the parallel-to-serial converter samples ws on positive edges of sck and outputs data on the negative edge of sck. 1 = the parallel-to-serial converter samples ws on negative edges of sck and outputs data on positive edges of sck. 28:19 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . 18:17 nr_chan r/w 00 00 = only sd[0] is active. 01 = sd[0] and sd[1] are active. 10 = sd[0], sd[1], and sd[2] are active. 11 = sd[0], sd[1], sd[2] and sd[3] are active. each sd output receives either 1 or 2 channels depending on trans_mode. non-active channels receive 0 value samples. in mono modes, each channel of a sd output receives identical left and right samples. table 9: audio output port registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-18 16:8 wsdiv r/w 0x0 sets the divider used to derive ws from sck. set to 0...511 for a serial frame length of 1...512. note the frame size limitations discussed in section 23.4.6.1 on page 23-16. 7:0 sckdiv r/w 0x0 sets the divider used to derive sck from osclk. set to 0...255 for division by 1...256. offset 0x11 000c ao_framing?ma clock domain 31 polarity r/w 0 0 = serial frame starts with a ws negedge. 1 = serial frame starts with a ws posedge. this bit should not be changed during operation of audio out i.e., only update this bit when trans_enable = 0. 30 sspos4 r/w 0 start/stop bit position msb. note that sspos is a 5-bit ?ld, while bit sspos4 is non-adjacent for backwards compatibility in 16-bit/ sample modes. program this ?ld along with ao_framing[3:0]. 29:22 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . 21:13 leftpos r/w 0x0 de?es the bit position within a serial frame where the ?st data bit of the left channel is placed. the ?st bit of a serial frame is bit 0. 12:4 rightpos r/w 0x0 de?es the bit position within a serial frame where the ?st data bit of the right channel is placed. 3:0 sspos r/w 0x0 start/stop bit position. note that sspos is a 5-bit ?ld, while bit sspos4 is non-adjacent for backwards compatibility in 16-bit/ sample modes. program this ?ld along with ao_framing[30]. if datamode = msb ?st, transmission starts with the msb of the sample i.e., bit 15 for 16-bit/sample modes or bit 31 for 32-bit/ sample modes. sspos determines the bit index (0..31) in the parallel input word of the last transmitted data bit. if datamode = lsb ?st, sspos determines the bit index (0..31) in the parallel word of the ?st transmitted data bit. bits sspos up to and including the msb are transmitted i.e., up to bit 15 in 16-bit/ sample mode and bit 31 in 32-bit/sample mode. offset 0x11 0010 reserved?tl clock domain 31:0 reserved - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . offset 0x11 0014 ao_base1?tl clock domain 31:6 base1 r/w 0x0 base address of dma buffer1 in memory - must be a 64-byte aligned address in local memory. if changed it must be set before ack1. 5:0 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . offset 0x11 0018 ao_base2?tl clock domain 31:6 base2 r/w 0x0 base address of dma buffer2 in memory - must be a 64-byte aligned address in local memory. if changed it must be set before ack2. 5:0 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . table 9: audio output port registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 15: audio output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 15-19 offset 0x11 001c ao_size?ma clock domain 31:6 size r/w 0 dma buffer size in samples. the number of mono samples or stereo sample pairs is read from a dma buffer in memory before switching to the other dma buffer in memory. buffer size in bytes is as follows: 16 bps, mono: 2 * size 32 bps, mono: 4 * size 16 bps, stereo: 4 * size 32 bps, stereo: 8 * size 5:0 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . offset 0x11 0020 ao_cc?ma clock domain 31:16 cc1 r/w 0x0 the 16-bit value of cc1 is shifted into each emitted serial frame starting at bit position cc1_pos, as long as cc1_en is asserted. 15:0 cc2 r/w 0x0 the 16-bit value of cc2 is shifted into each emitted serial frame starting at bit position cc2_pos, as long as cc2_en is asserted. offset 0x11 0024 ao_cfc?ma clock domain 31:18 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . 17:10 cc1_pos r/w 0x0 de?es the bit position within a serial frame where the ?st data bit of cc1 is placed. 9:0 cc2_pos r/w 0x0 de?es the bit position within a serial frame where the ?st data bit of cc2 is placed. offset 0x11 0028?ff0 reserved?tl clock domain 31:0 reserved - a read returns 0xdeadabba. offset 0x11 0ff4 ao_pwr_dwn?tl clock domain 31:1 unused - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read . 0 pwr_dwn r/w 0 the bit is used to provide power control status for system software block power management. offset 0x11 0ffc ao_module_id?tl clock domain 31:16 id r 0x0120 module id. this ?ld identi?s the block as type audio out. 15:12 maj_rev r 0 major revision id. this ?ld is incremented by 1 when changes introduced in the block result in software incompatibility with the previous version of the block. first version default = 0. 11:8 min_rev r 0x2 minor revision id. this ?ld is incremented by 1 when changes introduced in the block result in software compatibility with the previous version of the block. first version default = 0. 7:0 aperture r 0 aperture size. identi?s the mmio aperture size in units of 4 kb for the ao block. ao has an mmio aperture size of 4 kb. aperture = 0: 4 kb. table 9: audio output port registers ?ontinued bit symbol acces s value description
1. introduction the audio input block can have up to four audio input ports. each audio input port supports single or dual-channel sources. hence the audio in block can support up to 8 channels of audio input (4 stereo channels). the audio in module provides a dma-driven serial interface to an off-chip stereo a/d converter, i 2 s subsystem or other serial data source. audio in provides all signals needed to connect to high quality, low cost oversampling a/d converters. the audio in module and external a/d converter (or i 2 s subsystem) together are capable of generating a programmable sample clock by dividing a precise oversampling clock, which is an input to this block. it is assumed that a programmable clock generator for a precise oversampling a/d system clock is present elsewhere in the chip. 1.1 features four channels of audio input per port 16 or 32-bit samples per channel programmable 1 hz to 100 khz sampling rate (note: this is a practical range. the actual sample rate is application dependent.) internal or external sampling clock source audio in autonomously writes sampled audio data to memory using buffering (dma) 16-bit and 32-bit mono and stereo pc standard memory data formats raw mode where the bits from all the active inputs are sampled by bit clock along with the frame sync signal (ws) and packed into one 8 bit byte in memory for software to tear apart. little or big-endian memory formats. remark: ac-97 codecs are not supported. chapter 16: audio input pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-2 2. functional description the audio in module has four major subsystems: a programmable sample clock generator, a serial-to-parallel converter, a dtl initiator interface that initiates transfer of parallel data to a dtl-to-memory bus adapter and a mmio type low latency dtl target interface for mmio con?uration registers. the sampling clock can be used as either master or slave to the external a/d device. the sampling clock synchronizes the serial-to-parallel converter with the source data stream. the samples enter the serial-to-parallel converter, which reformats the data for the initiator. the initiator streams the parallel data in to the dtl-to-memory bus adapter. all the buffering of data is done in this adapter. the adapter also acts as the dma engine and bursts data to memory using the address provided by the initiator. since buffering of data is heavily dependent on system level latency issues, it is best done in the adapter. hence the buffer is not present in this block and instead will be in the adapter and sized according to system requirements. figure 1: audio in block diagram clock divider/generator serial to parallel converter mmio registers logic dtl dma interface logic ai_osclk ai_sck ai_ws sck divider ws divider divider value divider value ai_sd[0] ai_sd[1] ai_sd[2] ai_sd[3] shift register shift register shift register shift register parallel data different framing/capture options dtl interface dtl interface serial clock
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-3 2.1 chip level external interface the audio in chip level i2s related external interface has seven pins ai_osclk, ai_sck, ai_ws and ai_sd[3:0]. these pins may be also referenced as osclk, sck, ws and sd[3:0]. the ai_osclk is a precise, programmable clock output intended to serve as the master system clock for the external a/d subsystem. the ai_osclk is generated from the clock module which is outside the audio in block. although conceptually the oversampling clock is an output at the chip level, at the audio in block level, this is an input. six other pins constitute a ?xible serial input interface ip. ai_sck = audio in serial clock ai_ws = audio in word select 0 = left channel 1 = right channel ai_sd[3:0] = audio in serial data using the audio in mmio registers, these pins can be con?ured to operate in a variety of serial interface framing modes, including but not limited to the following: standard stereo i 2 s (msb ?st, 1-bit delay from ws, left and right data in a frame). (for further details on i 2 s, refer to the ? 2 s bus speci?ation dated june 5 1996, in the multimedia ics data handbook ic22 by philips semiconductors, 1998.) lsb ?st with 1- to 32-bit data per channel complex serial frames of up to 512 bits/frame with ?alid sample?quali?r bit table 1: audio-in i2s related ports signal type description ai_osclk input oversampling clock. this can be programmed to emit any frequency up to 40 mhz with a resolution of better than 0.3 hz. it is intended for use as the 256 f s or 384 f s oversampling clock by external a/d subsystem.it is also used by the audio in block to generate ai_sck when it is in master mode. this is generated from the clock block, outside the audio in module. it is an output from the chip, but also an input to the audio input block. ai_sck in/out when audio in is programmed as the serial-interface timing slave (power-up default), sck is an input. sck receives the serial bit clock from the external a/d subsystem. this clock is treated as fully asynchronous to the main chip level clock. when audio in is programmed as the serial-interface timing master, sck is an output. sck drives the serial clock for the external a/d subsystem. the frequency is a programmable integral divide of the osclk frequency. sck is limited to 30 mhz. the sample rate of valid samples embedded within the serial stream is limited to 100 khz. ai_sd[3:0] input serial data from external a/d subsystem. data on these pins are sampled on positive or negative edges of sck as determined by the clock_edge bit in the ai_serial register. ai_ws in/out when audio in is programmed as the serial-interface timing slave (power-up default), ws acts as an input. ws is sampled on the same edge as selected for sd. when audio in is programmed as the serial-interface timing master, ws acts as an output. it is asserted on the opposite edge of the sd sampling edge. ws is the word-select or frame-synchronization signal from/to the external a/d subsystem.
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-4 raw sample mode where the serial data for each active serial channel is sampled at each sampling clock edge along with the ai_ws and transferred to memory as a byte. 2.2 general operations software initiates capture by providing two equal size empty buffers and putting their base address and size in the base1, base2 and size registers. once two valid (local memory) buffers are assigned, capture can be enabled by writing a ??to cap_enable. the audio in unit hardware will proceed to ?l buffer 1 with input samples. once buffer 1 ?ls up, buf1_full is asserted, and capture continues without interruption in buffer 2. if buf1_inten is enabled, a level triggered interrupt request is generated to the chip level interrupt controller. note that the buffers must be 64-byte aligned and must be a multiple of 64 samples in size (the six lsbits of ai_base1, ai_base2 and ai_size are always zero). software is required to assign a new, empty buffer to base1 and perform an ack1, before buffer 2 ?ls up. capture continues in buffer 2, until it ?ls up. at that time, buf2_full is asserted and capture continues in the new buffer 1, etc. upon receipt of an ack, the audio in hardware removes the related interrupt request line assertion at the next main clock edge. in normal operation, the chip level system controller and audio in hardware continuously exchange buffers without ever losing a sample. if the system controller fails to provide a new buffer in time, the overrun error ?g is raised. this ?g is not affected by ack1 or ack2; it can only be cleared by an explicit write of logic ??to ack_ovr. remark: reserved bits in mmio registers should be ignored when read and written as zeros. see section 4. on page 16- 15 .
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-5 3. operation 3.1 clock programming figure 2 illustrates the clocking capabilities of the audio input unit. driving the system is a square wave direct digital synthesizer (dds). the dds can be programmed to emit frequencies from approximately 1 hz to 40 mhz with a resolution of better than 0.3 hz. the dds and its control registers reside in the clocks module outside the audio in unit. the output of the dds is always sent on the osclk output pin. this output is intended to be used as the 256 f s or 384 f s system clock source for oversampling a/d converters. software may change the dds frequency setting dynamically, so as to adjust the input sampling rate to track an application dependent master reference. using the dds function, a high quality, low-jitter osclk is generated. 3.1.1 clock system operation sck and ws can be con?ured as input or output, as determined by the ser_master control ?ld. as an output, sck is a divided form of the osclk output frequency. the sckdiv register value is used to divide down the osclk frequency. see section 4. on page 16- 15 for more details. whether input or output, the sck pin signal is used as the bit clock for serial-parallel conversion. the value of sckdiv is determined by equation 12 : (12) remark: sckdiv is in the range 0-255. figure 2: audio in clock system and i/o interface osclk sck ws sd div n+1 sckdiv div n+1 ser_master serial to parallel wsdiv ai domain left0[31:0] right0[31:0] dds in clocks module 27mhz x 64 square wave dds 7 0 80 32 32 (e.g. 64xfs) (e.g. 256xfs) converter left2[31:0] left3[31:0] right1[31:0] right2[31:0] right3[31:0] sd1 sd2 sd3 0 left1[31:0] f aisck f aiosclk sckdiv 1 + ------------------------------- --- =
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-6 if set as output, ws can similarly be programmed using wsdiv to control the serial frame length from 1 to 512 bits. the number of bits per frame is equal to wsdiv + 1. t ab le 2 presents several sample rates with the appropriate sckdiv necessary to achieve a bit clock of 64 f s . the preferred application of the clock system options is to use osclk as a/d master clock, and let the a/d converter be timing master over the serial interface (ser_master = 0). in case of an external codec for common audio input and audio output use, it may not be possible to independently control the a/d and d/a system clocks. it is recommended that the audio out clock system dds is used to provide a single master a/d and d/a clock. the audio out or the d/a converter can be used as serial interface timing master, and audio in is set to be slave to the serial frame determined by audio out (audio in ser_master = 0, sck and ws externally wired to the corresponding audio out pins). in such systems, independent software control over a/d and d/a sampling rate is not possible, but component count is minimized. 3.2 reset-related issues the audio in unit is reset by a chip level hardware reset or by writing logic ??to the ai_ctl.reset register bit. as soon as the software reset bit is written, further mmio commands are held off until the software reset has taken effect in the ip clock domain and the reset state restored. upon reset, capture is disabled (cap_enable = 0), and buffer1 is the active buffer (buf1_active = 1). if the audio in module was operating in clock master mode (ser_master = 1) then a reset action prevents the sck clock to be generated. this prevents the reset to complete. therefore upon a software reset the ai module clock must be switched to the default 27 mhz (crystal input) in order to complete the reset. software should follow a series of steps to ensure that software reset happens correctly: 1. check to see if there is a valid clock present on the audio input external clock input. 2. if there is no clock, then write to the clocks block to switch the audio input clock to the 27 mhz oscillator. 3. apply software reset and poll the reset bit until it is cleared. 4. program the clocks block to switch the audio input external clock back to the external clock mode. table 2: sample rate settings f s osclk sckdiv sck 44.1 khz 256 f s 364f s 48.0 khz 256 f s 364f s 44.1 khz 384 f s 564f s 48.0 khz 384 f s 564f s
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-7 clocks are required to be running during hw/sw reset because synchronous reset is used to initialize the logic. the unique feature with audio is that unlike all other blocks in the system, the audio blocks default to the external clock source on any reset. if the external clock does not exist when a hw reset is applied, then the logic is left uninitialized without any indication. 3.3 register programming guidelines software needs to ensure that the cap_enable bit (bit 30, ai_ctl) is programmed after all the other registers have been programmed to ensure proper functionality. disabling and re-enabling capture here is a brief discussion on how the audio in block works if for some reason software needs to disable the capture and consequently re-enable it. the audio input module is continuously capturing and transferring data to memory through the adapter in the system. the adapter threshold should be suitably set to satisfy the system latency requirements. once the adapter fifo reaches the threshold, it will initiate a transfer to memory. this behavior will continue until the capture is disabled. once the capture is disabled, the audio in block will issue a flush to the adapter so that it can ?sh its fifo and hence all the pertinent data that would reach memory. however, it must be understood that disabling capture is not the same as applying software reset. even though capture is disabled, all the internal dma state machines have pointers pointing to addresses in memory corresponding to the transaction that was just completed. so if the software intends to re-enable capture from scratch with new pointers, there needs to be a software reset performed between disabling and re- enabling the capture, along with optional reprogramming of the registers. failure to do a software reset will result in the audio input module behaving as though the previous transaction is continuing with all the previous pointers active. 3.4 serial data framing the audio in unit can accept data in a wide variety of serial data framing conventions. figure 3 illustrates the notion of a serial frame. if polarity = 1, clock_edge = 0, and earlymode=0, a frame is de?ed with respect to the positive transition of the ws signal as observed by a positive clock transition on sck. (see section 4. .) each data bit sampled on positive sck transitions has a speci? bit position?.e., once the clock edge detects the ws transition, the next sample will be data bit position 0.
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-8 each subsequent clock edge de?es a new bit position. other combinations of polarity and clock_edge can be used to de?e a variety of serial frame bit position de?itions. further if the earlymode = 1, then the ?st data bit (position 0) will be the data bit sampled in the same clock edge in which the ws signal transition is detected.(see section 4. .) the capturing of samples is governed by framemode. if framemode = 00, every serial frame results in one sample from the serial-parallel converter. a sample is de?ed as a left/right pair in stereo modes or a single left channel value in mono modes. if framemode = 1y, the serial frame data bit in bit position validpos is examined. if it has value ?? a sample is taken from the data stream (the valid bit is allowed to precede or follow the left or right channel data provided it is in the same serial frame as the data). the left and right sample data can be in a lsb-?st or msb-?st form at an arbitrary bit position and with an arbitrary length. (see section 4. .) in msb-?st mode, the serial-to-parallel converter assigns the value of the bit at leftpos to left[msb]. subsequent bits are assigned, in order, to decreasing bit positions in the left data word, up to and including left[sspos]. bits left[sspos?:0] are cleared. hence, in msb-?st mode, an arbitrary number of bits are captured. they are left-adjusted in the 16(32)-bit parallel output of the converter. in lsb-?st mode, the serial to parallel converter assigns the value of the bit at leftpos to left[sspos]. subsequent bits are assigned, in order, to increasing bit positions in the left data word, up to and including left[msb]. bits left[sspos 1:0] are cleared. hence, in lsb-?st mode, an arbitrary number of bits are captured. they are returned left-adjusted in the 16(32)-bit parallel output of the converter. figure 3: audio in serial frame and bit position de?ition (polarity = 1, clock_edge = 0, earlymode = 0) sck ws sd 0 1 2 34 567 8 9 10 11 12 13 14 15 16 17 18 frame n 19 20 21 22 23 24 25 26 27 28 29 30 31 0 1 2 3 45 67 frame n+1 figure 4: audio in serial frame and bit position de?ition (polarity = 1, clock_edge = 0, earlymode = 1) sck ws sd 0 1 2 34 567 8 9 10 11 12 13 14 15 16 17 18 frame n 19 20 21 22 23 24 25 26 27 28 29 30 31 0 1 2 3 45 67 frame n+1
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-9 the following table shows the exact bit positions assigned for a data item ?? see figure 5 and t ab le 4 for an example of how the audio in module registers are set to collect 16-bit samples using the philips saa7366 i 2 s 18-bit a/d converter. (see section 4. .) the setup assumes the saa7366 acts as the serial master. for example, if it were desired to use only the 12 msbits of the a/d converter in figure 5 , use the settings of t ab le 4 with sspos set to four. this results in left[15:4] being set with data bits 0..11 and left[3:0] being set equal to zero. right[15:4] is set with data bits 32..43 and right[3:0] is set to zero. similarly, if it was desired to use only the 12 msbits, but send 32 bit samples to memory, use the settings of t ab le 4 with sspos set to 20. this results in left[31:20] being set with data bits 0...11 and left[20:0] being set equal to zero. right[31:4] is set with data bits 32...43 and right[20:0] is set to zero. table 3: bit positions assigned for each data item operating mode first bit last bit valid sspos values 16 bit/sample, msb-?st s[15] s[sspos] 0..15 16 bit/sample, lsb-?st s[sspos] s[15] 0..15 32 bit/sample, msb-?st s[31] s[sspos] 0..31 32 bit/sample, lsb-?st s[sspos] s[31] 0..31 figure 5: serial frame of the saa7366 18-bit i 2 s a/d converter (format 2 sws) 52 19 sck ws sd 0 1 23 left n (18) 18 31 32 33 34 right n (18) 50 51 62 63 01 left n+1 (18) table 4: example setup for saa7366 field value explanation ser_master 0 saa7366 is serial master. sckdiv 3 sck set to osclk/4 (not needed since ser_master = 0). wsdiv 63 serial frame length of 64 bits (not needed since ser_master = 0) polarity 0 frame starts with negative ws. framemode 00 take a sample of each serial frame. validpos n/a don? care (every frame is valid). leftpos 0 bit position 0 is msb of left channel and will go to left[15]. rightpos 32 bit position 32 is msb of right channel and will go to right[15]. datamode 0 msb ?st sspos 0 stop with left/right[0]. clock_edge 0 sample ws and sd on positive sck edges for i 2 s
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-10 3.5 memory data formats the audio in unit autonomously writes samples to memory in mono and stereo 16 and 32-bit per sample formats, as shown in figure 6 . successive samples are always stored at increasing memory address locations. 3.5.1 endian control the following table illustrates exactly how the audio inout block writes data in memory (byte) locations precisely after the correct endian swapping done at the adapter depending on the polarity of the big-endian bit in the global registers module. figure 6: audio in memory dma formats table 5: operating modes and memory formats nr_chan mode source of successive samples 00 mono (one channel) sd0.left 00 stereo (one channel) sd0.left, sd0.right 01 mono (two channels) sd0.left, sd1.left 01 stereo (two channels) sd0.left, sd0.right, sd1.left, sd1.right 10 mono (three channels) sd0.left, sd1.left, sd2.left 10 stereo (three channels) sd0.left, sd0.right, sd1.left, sd1.right, sd2.left, sd2.right 11 mono (four channels) sd0.left, sd1.left, sd2.left, sd3.left 11 stereo (four channels) sd0.left, sd0.right, sd1.left, sd1.right, sd2.left, sd2.right, sd3.left, sd3.right. 16 bit, stereo, nr_chan=00 16 bit, stereo, nr_chan=10 32 bit, stereo, nr_chan=00 adr sd0.left n adr sd0.left n adr sd0.left n adr+2 sd0.right n adr+2 sd0.right n adr+4 sd0.left n+1 adr+4 sd1.left n adr+4 sd0.right n adr+6 sd0.right n+1 adr+6 sd1.right n adr+8 sd0.left n+2 adr+8 sd2.left n adr+10 sd0.right n+2 adr+10 sd2.right n adr+8 sd0.left n+1 adr+12 adr+14 sd0.left n+3 sd0.right n+3 adr+12 adr+14 sd0.left n+1 sd0.right n+1 adr+12 sd0.right n+1 32 bit, stereo, nr_chan=10 sd0.left n sd0.right n sd1.left n sd1.right n sd2.left n sd2.right n sd0.left n+1 sd0.right n+1 adr adr+4 adr+8 adr+12 adr+16 adr+20 adr+24 adr+28 32 bit, mono, nr_chan=00 adr sd0.left n adr+4 sd0.left n+1 adr+8 sd0.left n+2 adr+12 sd0.left n+2 table 6: endian ordering of audio data in main memory operating modes m[adr] m[adr+1] m[adr+2] m[adr+3] m[adr+4] m[adr+5] m[adr+6] m[adr+7] 16-bit mono - little endian left n [7:0] left n [15:8] left n+1 [7:0] left n+1 [15:8 ] left n+2 [7:0] left n+2 [15:8] left n+3 [7:0] left n+3 [15:8] 16-bit mono - big endian left n [15:8] left n [7:0] left n+1 [15:8 ] left n+1 [7:0] left n+2 [15:8] left n+2 [7:0] left n+3 [15:8] left n+3 [7:0] 16-bit stereo - little endian left n [7:0] left n [15:8] right n [7:0] right n [15:8] left n+1 [7:0] left n+1 [15:8] right n+1 [7:0] right n+1 [15:8 ]
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-11 3.6 memory buffers and capture the audio input unit hardware implements a double buffering scheme to ensure that no samples are lost, even if the chip level controller is highly loaded and slow to respond to interrupts. the software assigns buffers by writing a base address and size to the mmio control ?lds (see section 4. on page 16- 15 ). in 16-bit capture modes, the sixteen msbits of the serial-to-parallel converter output data are written to memory. in 32-bit capture modes, all bits of the parallel data are written to memory. if sign_convert is set to one, the msb of the data is inverted, which is equivalent to translating from twos complement to offset binary representation. this allows the use of an external twos complement 16-32 bit a/d converter to generate 16-32 bit unsigned samples. remark: the audio in hardware does not generate a-law or -law data formats. if such formats are desired, additional processing is necessary, via software, to convert from 16-bit linear data to a-law or -law data. 3.7 data bus latency and hbe audio in uses a 128-byte buffer to capture the audio input samples. when 64-bytes of space is full, the next incoming samples are continuously stored in the remaining 64-byte space while the adapter issues dma request for the ?st 64 bytes of data. under normal operation, the ?st 64-bytes worth data gets written to memory while the second 64-bytes worth data is being ?led up. this normal operation will be maintained as long as the data bus arbiter is set to guarantee a latency for audio in that matches the incoming audio samples rate. given a sample rate f s , and an associated sample interval t (in nsec), the bus latency should be at most 16*t nsec in the case of 16 bit samples and 8t nsec in the case of 32 bit samples, for 2 audio channels. similarly for 4 channels (8t, 4t), 6 channels (16t/3, 8t/3) and 8 channels (4t, 2t) respectively. if this max latency is not satis?d, the hbe (bandwidth error) condition will result. this error ?g gets set when the 128-byte buffer is full and a new sample arrives for that buffer. thus hbe error condition occurs when the adapter is unable to transfer data from its fifo to memory in time. hence the adapter fifo gets full and is not able to accommodate valid data coming from the audio in block. this results in an hbe condition. t ab le 7 16-bit stereo - big endian left n [15:8] left n [7:0] right n [15:8] right n [7:0] left n+1 [15:8] left n+1 [7:0] right n+1 [15:8 ] right n+1 [7:0] 32-bit mono - little endian left n [7:0] left n [15:8] left n [23:16] left n [31:24] left n+1 [7:0] left n+1 [15:8] left n+1 [23:16] left n+1 [31:24] 32-bit mono - big endian left n [31:24] left n [23:16] left n [15:8] left n [7:0] left n+1 [31:24 ] left n+1 [23:16 ] left n+1 [15:8] left n+1 [7:0] 32-bit stereo - little endian left n [7:0] left n [15:8] left n [23:16] left n [31:24] right n [7:0] right n [15:8] right n [23:16] right n [31:24] 32-bit stereo - big endian left n [31:24] left n [23:16] left n [15:8] left n [7:0] right n [31:24] right n [23:16] right n [15:8] right n [7:0] table 6: endian ordering of audio data in main memory ?ontinued operating modes m[adr] m[adr+1] m[adr+2] m[adr+3] m[adr+4] m[adr+5] m[adr+6] m[adr+7]
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-12 shows the required data bus arbitration latency requirements for a number of common operating modes, for 2 channels. the right column in t ab le 7 shows the nature of the resulting 64-byte burst data bus requests. in the raw mode however, the sampling is much faster. one eight bit byte is sampled every sck. hence one 32 bit word (4 bytes) are transferred every four clocks. so for example if the sample clock sck is about 25 mhz, then the bandwidth requirement would be 40 mbytes per second. obviously this requirement is much higher than in the usual serial mode for this block. 3.8 error behavior if either an overrun or hbe error occurs, input sampling is temporarily halted and incoming samples will be lost. in the case of overrun, sampling resumes as soon as the control software makes one or more new buffers available through an ack1 or ack2 operation. in the case of hbe, sampling will resume as soon as the data in the fifo can be written to memory. hbe and overrun are ?ticky error ?gs meaning they will remain set until an explicit software write of logic ??to ack_hbe or ack_ovr is performed. see section 4. on page 16- 15 . 3.9 interrupts the ai_status register provides all sources of audio in generated interrupt: buf1_full, buf2_full, hbe and overrun. all interrupts sourced by audio in to the chip level interrupt controller are level triggered. an interrupt will be generated from audio in only if the corresponding interrupt enable bit is set in the ai_ctl register. for example, to assert an interrupt to the system upon the occurrence of a bandwidth error (hbe asserted), set the hbe_inten bit to logic ?? see section 4. . table 7: audio in data bus arbiter latency requirement examples ?16-bit data examples capmode 2 channels f s (khz) t (ns) max arbiter latency (16*t) (usec) access pattern stereo 2x16 bits/sample 44.1 22,676 362.816 1 64-byte request minimally every 362.816 us stereo 2x16 bits/sample 48.0 20,833 333.328 1 64-byte request minimally every 333.328 us stereo 2x16 bits/sample 96.0 10,417 166.672 1 64-byte request minimally every 166.672 us table 8: audio in data bus arbiter latency requirement examples ?32-bit data examples capmode 2 channels f s (khz) t (ns) max arbiter latency (8*t) (usec) access pattern stereo 2x32 bits/sample 44.1 22,676 181.408 1 64-byte request minimally every 181.408us stereo 2x32 bits/sample 48.0 20,833 166.66 1 64-byte request minimally every 166.66 us stereo 2x32 bits/sample 96.0 10,417 83.34 1 64-byte request minimally every 83.34 us
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-13 interrupt status bits within ai_status are persistent, meaning that once the interrupt is triggered, it will remain asserted until cleared by setting the corresponding ack bit in ai_ctl. using the above example, assuming the hbe interrupt is asserted, write a logic ??to ack_hbe to clear the ai_status.hbe bit and deactivate the interrupt to the system. 3.10 timestamp events audio in exports event signals associated with audio capture to the central timestamp/timer function on-chip. the central timestamp/timer function can be used to count the number of occurrences of each event or timestamp the occurrence of the event or both. the event will be a positive edge pulse with the duration of the event to be greater than or equal to 160ns. the speci? event exported is: the ai_tstamp_event event will occur when the last sample for the current dma buffer reaches the internal buffer. the internal buffer referred to here is present in the adapter and not inside the audio in block. one precise event will occur for each of the two dma buffers. the occurrence of this event represents a precise, periodic time interval which can be used by system software for audio/video synchronization. 3.11 diagnostic mode this mode can be used during the diagnostic phase of system testing to verify the correct operation of both audio in and audio out units. this loopback mode internally feeds the i2s audio out to the i2s audio in. this test can be used to check the data ?w from the audio out buffer to the audio in buffer. audio in operation the audio (i2s) input ports registers ( section 4. on page 16- 15 ) describe the function of the control and status ?lds of the ai unit. to ensure compatibility with future devices, unde?ed bits in mmio registers should be ignored when read and written as 0s. the ai unit is reset by a pnx15xx series hardware reset, or by writing 0x80000000 to the ai_ctl register. upon reset, capture is disabled (cap_enable = 0), and buffer1 is the active buffer (buf1_active = 1). the cpu initiates capture by providing two equal size empty buffers and putting their base address and size in the basen and size registers. once two valid (local memory) buffers are assigned, capture can be enabled by writing a ??to cap_enable. the ai unit now proceeds to ?l buffer 1 with input samples. once buffer 1 ?ls up, buf1_full is asserted, and capture continues without interruption in buffer 2. if buf1_inten is enabled, a source 11 interrupt request is generated. note that the buffers must be 64-byte aligned and multiple of 64 samples in size (the six lsbits of ai_base1, ai_base2 and ai_size are always ??. the cpu is required to assign a new, empty buffer to base1 and perform a ack1 before buffer 2 ?ls up. capture continues in buffer 2 until it ?ls up. at that time, buf2_full is asserted and capture continues in the new buffer 1.
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-14 upon receipt of an ack, the ai hardware removes the related interrupt request line assertion at the next cpu clock edge. the ai interrupt should always be operated in level-sensitive mode since ai can signal multiple conditions that each need independent acks over the single internal source 11 request line. in normal operation, the cpu and ai hardware continuously exchange buffers without ever losing a sample. if the cpu fails to provide a new buffer in time, the overrun error ?g is raised. the ?g is not affected by ack1 or ack2; it can only be cleared by an explicit ack-ovr. 3.12 software reset bit 31 of the ai_ctl register is the software reset bit for the audio input module. the purpose of sw reset register bit is to cleanly abort dma traf?, reset the audio input logic and reset all mmio registers. sw reset must not hang the mmio bus interface (i.e. mmio bus state machine is not reset). although the ip clock should be running (i.e. not gated off to save power) when the sw reset bit is written, the system will not hang if a sw reset is executed when the clocks are off (this means in master mode that the clock needs to be switched to the 27 mhz crystal clock since ser_master is also reset and therefore the clock is removed. remark: that sw reset makes no attempt to stop dma data transfer in a precise manner. the following sequence takes place following a software reset: 1. cpu sets the sw reset bit via an mmio interface write and then polls that bit waiting for it to be cleared indicating reset completion. 2. although this mmio interface write completes immediately, accesses to all other registers are disabled until a round trip handshake with the audio input clock domain indicates that all sw reset action is complete. if a read to a register other than the sw reset register occurs while the interface is disabled then the error condition and 0xdeadaba data are immediately returned. if a read to the sw reset register occurs then a 1 is returned immediately with no error condition to indicate that the sw reset is still in progress. a toggle style handshake between the bus and audio input clock domains is already built into the new mmio interface register for sw reset. the audio input completes the following actions before the handshake completion signal is asserted: a) disable the streaming interface b) abort dma c) reset ip logic d) reset mmio registers in both audio input and bus clock domains 3. the sw reset handshake is asserted to indicate that the above actions in both clock domains are complete. this causes the sw reset bit to be de-asserted and the mmio interface to be enabled.
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-15 3.13 raw mode apart from the usual i 2 s mode and the early mode, capture can also be enabled in the raw mode. at every sample clock (sck) the data bit(s) from each active channel is capture along with the ws. this information is then formed as a byte. after four such bytes are formed, the resulting 32-bit data is transferred to memory. hence every sample clock results in a byte of data for software to tear apart and manipulate. the following table shows how the data bits, and the ws are sampled with respect to the different channels and formed in to a byte that gets transferred to memory. 4. register descriptions the register descriptions for the audio in block are given below. the base address for the audio in registers begins at offset 0x11 1000. 4.1 register table table 9: raw mode format of input data and word select bit 7 bit 6 bit 5 bit 4 bit 3 bit2 bit 1 bit 0 0 0 0 sd[3] sd[2] sd[1] sd[0] ws table 10: register summary offset name description 0x11 1000 ai_status provides status of audio in components/situations. 0x11 1004 ai_ctl control register to con?ure audio in options 0x11 1008 ai_serial control register to con?ure audio in serial timing and data options 0x11 100c ai_framing control register to con?ure data framing format 0x11 1010 reserved 0x11 1014 ai_base1 base address of buffer 1 0x11 1018 ai_base2 base address of buffer 2 0x11 101c ai_size the dma buffer size in samples 0x11 1020?ff0 reserved 0x11 1ff4 ai_pwr_dwn powerdown function. implementation details not decided yet. 0x11 1ffc ai_module_id module id number, including major and minor revision levels table 11: audio (i 2 s) input ports registers bit symbol acces s value description note: the clock frequency emitted by the ai_osclk output is set in registers that control the clock block in the chip. offset 0x11 1000 ai_status 31:5 unused - 4 buf1_active r 1 1 = buffer will be used for the next incoming sample. 0 = buffer 2 will receive the next sample. 3 overrun r 0 an overrun error has occurred i.e., software failed to provide an empty buffer in time and 1 or more samples have been lost. 2 hbe r 0 bandwidth error
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-16 1 buf2_full r 0 1 = buffer 2 is full. if buf2_inten is also 1, an interrupt request is pending. 0 buf1_full r 0 1 = buffer 1 is full. if buf1_inten is also 1, an interrupt request is pending. offset 0x11 1004 ai_ctl 31 reset r/w 0 the audio in logic is reset by writing a 0x80000000 to ai_ctl. this bit is set during software reset and is cleared at the completion of software reset. software can poll this bit and when it reads a 0, it knows that the reset is done. 30 cap_enable r/w 0 capture enable ?g: 0 = audio in is inactive. 1 = audio in captures samples and acts as dma master to write samples to local memory. 29:28 cap_mode r/w 00 00 = mono (left adc only), 32 bits/sample 01 = stereo, 2 times 32 bits/sample 10 = mono (left adc only), 16 bits/sample 11 = stereo, 2 times 16 bits/sample 27 sign_convert r/w 0 0 = leave msb unchanged. 1 = invert msb. 26 earlymode r/w 0 setting this bit will enable the audio input port to capture data in a mode where the ?st data bit is driven on the same clock edge during which ws is driven. so in this mode the data is sampled one clock early compared to the standard i2s mode. 0 = standard i2s mode. first data bit expected the next clock after ws has been sampled. 1 = early mode. first data bit expected the same clock during which ws has been sampled. 25 diagmode r/w 0 0 = normal operation 1 = diagnostic mode 24 rawmode r/w 0 0 = normal i2s mono/stereo capture formats. 1 = serial stream is captured in a raw mode. at every sample clock (sck) the data bit(s) from each active channel is capture along with the ws. this information is then transferred to memory as a byte. hence every sample clock results in a byte of data transferred to memory for software to tear apart and manipulate. 23:8 unused - 7 ovr_inten r/w 0 overrun interrupt enable: 0 = no interrupt 1 = interrupt if an overrun error occurs. 6 hbe_inten r/w 0 hbe interrupt enable: 0 = no interrupt 1 = interrupt if a bandwidth error occurs. 5 buf2_inten r/w 0 buffer 2 full interrupt enable: 0 = no interrupt 1 = interrupt if buffer 2 full. 4 buf1_inten r/w 0 buffer 1 full interrupt enable: 0 = no interrupt 1 = interrupt if buffer 1 full. table 11: audio (i 2 s) input ports registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-17 3 ack_ovr r/w 0 write a 1 to clear the overrun ?g and remove any pending overrun interrupt request. this bit always reads as 0. 2 ack_hbe r/w 0 write a 1 to clear the hbe ?g and remove any pending hbe interrupt request. this bit always reads as 0. 1 ack2 r/w 0 write a 1 to clear the buf2_full ?g and remove any pending buf2_full interrupt request. ai_base2 must be valid before setting ack2. this bit always reads as 0. 0 ack1 r/w 0 write a 1 to clear the buf1_full ?g and remove any pending buf1_full interrupt request. ai_base1 must be valid before setting ack2.this bit always reads as 0. offset 0x11 1008 ai_serial 31 ser_master r/w 0 sets clock ratios and internal/external clock generation. 0 = the a/d converter is the timing master over the serial interface. ai_sck and ai_ws pins are set to be input. 1 = audio in serial interface is the timing master over the external a/d. the ai_sck and ai_ws pins are set to be outputs. 30 datamode r/w 0 0 = msb ?st 1 = lsb ?st 29:28 framemode r/w 00 this mode governs capturing of samples. 00 = accept a sample every serial frame. 01 = unused, reserved 10 = accept sample if valid bit = 0. 11 = accept sample if valid bit = 1. 27 clock_edge r/w 0 0 = the sd and ws pins are sampled on positive edges of the sck pin. if ser_master = 1, ws is asserted on sck negative edge. 1 = sd and ws are sampled on negative edges of sck. as output, ws is asserted on sck positive edge. 26:20 unused - 19 sspos4 r/w 0 start/stop bit msb. note that sspos is actually a 5 bit ?ld, and this is the msb sspos[4]and is non-adjacent to the bits sspo[3:0] due to software compatibility reasons. program this ?ld along with ai_framing[3:0]. 18:17 nr_chan r/w 00 00 = only sd[0] is active. 01 = sd[0] and [1] are active. 10 = sd[0], [1], and [2] are active. 11 = sd[0]..sd[3] are active. each sd input receives either 1 or 2 channels depending on cap_mode. in mono modes, the samples are captured from the left channel. 16:8 wsdiv r/w 0 sets the divider used to derive ai_ws from ai_sck. set to 0..511 for a serial frame length of 1..512. 7:0 sckdiv r/w 0 sets the divider used to derive ai_sck from ai_osclk. set to 0..255, for division by 1..256. offset 0x11 100c ai_framing 31 polarity r/w 0 sets format of serial data stream. 0 = serial frame starts on ws negative edge. 1 = serial frame starts on ws positive edge. table 11: audio (i 2 s) input ports registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-18 30:22 validpos r/w 0 de?es bit position within a serial frame where the valid bit is found. 21:13 leftpos r/w 0 de?es bit position within a serial frame where the ?st data bit of the left channel is found. 12:4 rightpos r/w 0 de?es bit position within a serial frame where the ?st data bit of the right channel is found. 3:0 sspos_3_0 r/w 0 start/stop bit position. if datamode = msb ?st, sspos determines the bit index (0..15) for 16 bit samples and (0...31) for 32 bit samples, in the parallel word of the last data bit. bits 15 or 31 (msb) up to and including sspos are taken in order from the serial frame data. all other bits are set to zero. if datamode = lsb ?st, sspos determines the bit index (0..15) for 16 bit samples and (0...31) for 32 bit samples, in the parallel word of the ?st data bit. bits sspos up to and including 15 or 31 (msb) are taken in order from the serial frame data. all other bits are set to zero. note: refer also to ai_serial[19] offset 0x11 1010 reserved offset 0x11 1014 ai_base1 31:6 base1 r/w 0 base address of buffer 1 must be a 64-byte aligned address in local memory. if changed it must be set before ack1. 5:0 reserved offset 0x11 1018 ai_base2 31:6 base2 r/w 0 base address of buffer 1 must be a 64-byte aligned address in local memory. if changed it must be set before ack2. 5:0 reserved offset 0x11 101c ai_size 31:6 size r/w 0 sets number of samples in buffers before switching to other buffers. in stereo modes, a pair of 16-bit or 32-bit data counts as 1 sample. in mono modes, a single value counts as a sample.buffer size in bytes is as follows: 16 bps, mono: 2 * size 32 bps, mono: 4 * size 16 bps, stereo: 4 * size 32 bps, stereo: 8 * size during raw mode the sample size is always 8 bits. hence buffer size in bytes for the raw mode is size. 5:0 reserved offset 0x11 1020?ff0 reserved offset 0x11 1ff4 ai_pwr_dwn 31:1 unused - table 11: audio (i 2 s) input ports registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 16: audio input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 16-19 0 pwr_dwn r/w 0 the bit is used to provide power control status for system software block power management. implementation details yet to be worked out. offset 0x11 1ff8 module_id_ext 31:0 unused r/w - the audio in block does not use this register. this always reads 0. offset 0x11 1ffc ai_module_id 31:16 id r 0x010d module id. this ?ld identi?s the block as type audio in. 15:12 maj_rev r 0x1 major revision id. this ?ld is incremented by 1 when changes introduced in the block result in software incompatibility with the previous version of the block. first version default = 0. 11:8 min_rev r 0x1 minor revision id. this ?ld is incremented by 1 when changes introduced in the block result in software compatibility with the previous version of the block. first version default = 0. 7:0 aperture r 0 aperture size. identi?s the mmio aperture size in units of 4 kb for the ai block. ai has an mmio aperture size of 4 kb. aperture = 0: 4 kb. table 11: audio (i 2 s) input ports registers ?ontinued bit symbol acces s value description
1. introduction the spdif output (spdo) block generates a 1-bit high-speed serial data stream. the primary application is to generate spdif (sony/philips digital interface) data for use by external audio equipment. 1.1 features the spdif output has the following features: fully compliant with iec-60958, for both consumer and professional applications supports two channel linear pcm audio, with 16-24 bit/sample supports one or more dolby digital ac-3 6 channel data streams embedded as iec-61937 supports one or more mpeg-1 or mpeg-2 audio streams embedded as per iec- 61937 allows arbitrary, programmable, sample rates from 1 hz to 300 khz spdo can carry data with a sample rate independent of and asynchronous to the audio out sample rate spdo hardware performs autonomous dma of memory resident iec-60958 sub- frames spdo hardware performs parity generation and bi-phase mark encoding software has full control over all data content, including user and channel data remark: iec-61937 is a generic specification for transmitting non pcm data with an iec-60958 transport.it supports ac3, pts, mpeg1 layer3 (mp3). mpeg 2 bc, mpeg 2 aac and others. it is possible to use the spdo signal as a general purpose high-speed data stream. potential applications include use as a high-speed uart or high speed serial data channel. in this case, the features include: up to 40 mbit/sec data rate full software control over each bit cell transmitted lsb ?st or msb ?st data format chapter 17: spdif output pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-2 2. functional description 2.1 architecture the spdo module has two basic components: a dma engine and an emitter. the emitter is clocked from the dds (in the clock module) and can be programmed to the desired sample rare. the emitter delivers the data stream to the spdif output pin. 2.2 general operations software initially gives spdo two memory data buffers, then enables the spdo block. as soon as the ?st memory buffer is drained, spdo requests a new buffer from software while switching over the use the other memory buffer, and so on. with the exception of the dds operation, the spdo block is generally software compatible with that of the pnx1300 series. 3. operation 3.1 clock programming a programmable clock generated by the spdo direct digital synthesizer (dds). note that the dds resides in the central clocks module. 3.1.1 sample rate programming in spdif, the frame rate always equals f s , the sample rate of embedded audio. this relation holds for pcm as well as for ac-3 and mpeg audio. each frame consists of 128 unit intervals (uis). the length of a ui is determined by the frequency setting of the spdo direct digital synthesizer (dds) in the central clock module. (13) the dds can be programmed to emit on chip frequencies from approximately. 1 hz to 80 mhz with a maximum jitter of less than 0.579 ns. refer to chapter 5 the cloc k module for details. t ab le 1 shows settings for common sample rate and main clock values. table 1: spdif out sample rates and jitter f s (khz) ui (nsec) jitter (nsec) 32.000 244.14 0.579 44.100 177.15 0.579 48.000 162.76 0.579 96.000 81.38 0.579 f s f dds () 128 ------------- --- - =
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-3 3.2 register programming guidelines before enabling the spdo block, software must assign two buffers with data to spdo_base1, spdo_base2 and a buffer size value (in bytes) to spdo_size. each memory buffer size must be a multiple of 64 bytes, regardless of the operating mode. the spdo block is enabled by writing a ??to spdo_ctl.trans_enable. once enabled, the ?st dma buffer is sent out at the programmed sample rate. once the ?st buffer is empty, buf1_active is negated and the buf1_empty ?g in spdo_status is asserted. if buf1_inten in spdo_ctl is asserted, an interrupt to the chip level interrupt controller is generated. the spdo block continues by emitting the data in dma buffer2. in normal operation, software assigns a new buffer 1 full of data to spdo and signals this by writing a ? to ack_buf1. the spdo block immediately negates the buf1_empty condition and the related interrupt request. once buffer2 is empty, similar signalling occurs and the hardware switches back using buffer1. transmission continues interrupted until the unit is disabled. the spdo module has two operating modes: spdif and transparent dma mode. iec mode spdif driver software assembles spdif data in each memory data buffer. each memory data buffer consists of groups of 32 bit words in memory. each word describes the data to be transmitted for a single iec-60958 sub-frame, including what type of preamble to include. each sub-frame is transmitted in 64 clock intervals of the spdo clock. the spdif mode is also useful for providing a source input stream for an available spdif in block. transparent dma mode in transparent dma mode, software prepares each data bit exactly as it is to be transmitted, in a series of 32 bit words in each memory data buffer. the 32 bit word is constructed according to the byte ordering rules of little or big-endian mode. each 32- bit word is transmitted (lsb or msb ?st) into 32 clock intervals of the dds. the data is shifted out ?s is, without bi-phase mark encoding, parity generation or preamble insertion.
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-4 3.3 data formatting 3.3.1 iec-60958 serial format figure 1 shows the serial format layout of an iec-60958 block. a block starts with a special ??preamble, and consists of 192 frames. the sample rate of all embedded audio data is equal to the frame rate. each frame consists of 2 subframes. subframe 1 always starts with an ??preamble, except for subframe 1 in frame 0, which starts with a ?? subframe 2 always starts with a ??preamble. when iec-60958 data carries two-channel pcm data, one audio sample is transmitted in each sub-frame, ?eft?in sub-frame 1 and ?ight?in sub-frame 2. each sample can be 16-24 bit, where the msb is always aligned with bit slot 27 of the sub- frame. in case of more than 20 bits per sample, the aux ?ld is used for the 4 lsb bits. when iec-60958 data carries non-pcm audio, such as 1 or more streams of encoded ac-3 data and/or mpeg audio, each sub-frame carries 16 bits data. the data of successive frames adds up to a payload data-stream which carries its own burst-data. this is described in the ?nterface for non-pcm encoded audio bitstreams applying iec958. philips consumer electronics, june 6 1997, iec 100c/wg11 (preliminary for iec-61937). figure 1: serial format of a iec-60958 block channel 1 m channel 2 w channel 1 b channel 2 w channel 1 m channel 2 w start of block (indicated by unique b pre-amble) sub-frame 1 sub-frame 2 frame 0 frame 1 channel 1 m frame 191 0 31 28 24 20 16 12 8 4 sample data l s b m s b b, w or m pre-amble aux. vucp validity flag user data channel status parity bit sub-frame (2 channel pcm) 0 31 28 24 20 16 12 8 4 16 bits data l s b m s b b, w or m pre-amble vucp validity flag user data channel status parity bit sub-frame (non-pcm audio) unused (0)
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-5 programmers should refer to the iec-60958 digital audio interface , ?art 1:general; part 2: professional applications; part 3: consumer applications?for a precise description of the required values in each ?ld for different types of consumer equipment. the spdo block hardware only generates b, w and m preambles as well as the p (parity) bit. all other bits in the sub-frame are completely determined by software and copied ?s is?from memory to output, subject only to bit-cell coding. software must construct valid iec-60958 blocks by using the right sequence of 32-bit words as described in section iec-60958 memor y data f or mat iec-60958 bit cell and preamble each data bit in iec-60958 is transmitted using bi-phase mark encoding. in bi-phase mark encoding, each data bit is transmitted as a cell consisting of two consecutive binary states. the ?st state of a cell is always inverted from the second state of the previous cell. the second state of a cell is identical to the ?st state if the data bit value is a ?? and inverted if the data bit value is a ?? preambles are coded as bi-phase mark violations, where the ?st state of a cell is not the inverse of the last state of the previous cell. the duration of each state in a cell is called a ui (unit interval), so that each cell is 2 uis long. in spdo, the length of a ui is 1 spdo clock cycle as determined by the settings of the dds (see section 3.1.1 sample rate prog r amming ). figure 2 illustrates the transmission format of 8 bit data value ?0011000? as well as the transmission format of the three preambles. note that each preamble always starts with a rising edge. this is made possible by the presence of the parity bit, which always guarantees an even number of ??bits in each subframe. figure 2: bi-phase mark data transmission ? ? ? ? ? ? ? ? ui cell bi-phase mark violation bi-phase mark violation bi-phase mark violation nrz bi-phase mark b preamble m preamble w preamble
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-6 iec-60958 parity the parity bit, or p bit in figure 1 , is computed by the spdif out hardware. the p bit value should be set such that bit cells 4 to 31 inclusive contain an even number of ones (and hence even number of zeroes). the p bit is bi-phase mark encoded using the same method as for all other bits. iec-60958 memory data format the system software must prepare a memory data structure that instructs the spdif block hardware to generate correct iec-60958 blocks. this data structure consists of 32-bit words with the content described in table 5.3: the data structure for a block consists of 384 of these 32-bit descriptor words, one for each subframe of the block, with the correct b, m, w values. all data content, including the u, c and v ?g are fully under control of the software that builds each block. a dma buffer handed to the hardware is required to be a multiple of 64 bytes in length. it can contain 1 or more complete blocks, or a block may straddle dma buffer boundaries. the 64 byte length will result in dma buffers that contain a multiple of 16 subframes. 3.3.2 transparent mode when spdo is set to operate in transparent mode, it takes all 32-bits of the memory data and shifts them out as is, without bi-phase mark encoding, parity generation or preamble insertion. two transparent modes are provided, as determined by the trans_mode ?ld in spdo_ctl: lsb ?st and msb ?st. one bit of memory data is transmitted for each dds clock. the 32-bit memory word is constructed according to the same rules for byte ordering as in section iec-60958 memor y data f or mat above. 3.4 errors and interrupts 3.4.1 dma error conditions two types of errors can occur during dma operation. table 2: spdif subframe descriptor word bits de?ition 31 (msb) this bit must be a ??for future compatibility. 30..4 data value for bits 4..30 of the subframe, exactly as they are to be transmitted. hardware will perform the bi-phase mark encoding and parity generation. 3..0 (lsb) 0000 - generate a b preamble 0001 - generate an m preamble 0010 - generate a w preamble 0011 .. 1111 reserved for future
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-7 if the software fails to provide a new buffer of data in time, and both dma buffers empty out, the spdo hardware raises the underrun ?g in spdo_status. transmission switches over to the use of the next buffer, but the data transmitted is from the previously transmitted buffer. if udr_inten is asserted, an interrupt will be generated. the underrun ?g is sticky - it will remain asserted until the software clears it by writing a ??to ack_udr. a lower level error can also occur when the limited size internal buffer empties out before it can be re?led across the data bus. this situation can arise only if insuf?ient bandwidth is allocated to spdo from the bus arbiter. in this case, the highway bandwidth error (hbe) error ?g is raised. 3.4.2 hbe and latency if the arbiter is set up with an insuf?ient latency guarantee, a situation can arise that requested data will not arrive in time, (when a new output sample is due). in that case the hbe error is raised, and the last sample for each channel will be repeated until the new buffer is refreshed. the hbe condition is sticky, and can only be cleared by an explicit ack_hbe. this condition indicates an incorrect setting of the arbiter. the arbiter needs to guarantee that the maximum latency required by the spdo block can always be met. given an output data rate f s in samples/sec, 2 x 32 bits are required each sample interval. the arbiter should be set to have a latency so that the buffer is re?led before a sample interval expires. refer to t ab le 3 for example latency requirements. 3.4.3 interrupts the spdo block generates an interrupt if one of the following status bit ?gs, and its corresponding inten ?g are set: buf1_empty, buf2_empty, hbe, underrun. see offset 0x10 9000 spdo_st a tus for details. all these status ?gs are ?ticky? i.e. they are asserted by hardware when a certain condition occurs, and remain set until the interrupt handler explicitly clears them by writing a ??to the corresponding ack bit in spdo_ctl. the spdo hardware takes the ?g away in the clock cycle after the ack is received. this allows immediate return from interrupt once performing an ack. 3.4.4 timestamp events spdo exports event signals associated with audio transmission to the central timestamp/timer function on-chip. the central timestamp/timer function can be used to count the number of occurrences of each event or timestamp the occurrence of the event or both. the event will be a positive edge pulse with the duration of the event to be greater than or equal to 200 ns. the speci? event exported is as follows: table 3: spdo block latency requirements f s (khz) 1/f s (nsec) max. latency (9/ f s) (usec) 32.000 31250 281 44.100 22675 204 48.000 20833 187 96.000 10416 94
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-8 buf_done - signals when the last word of a memory buffer is being requested by the spdo module. note that this event is not dependent upon memory bus latency. the occurrence of this event represents a precise, periodic time interval which can be used by system software for audio/video synchronization. 3.5 endian mode the spdif descriptor is a 32-bit word memory data structure, 4. signal description 4.1 external interface an external circuit as shown in figure 3 is required to provide an electrically isolated output and convert the 3.3 volt output pin to a drive level of 0.5 v peak-peak into a 75 ohm load, as required for consumer applications of iec-60958. 5. register descriptions the base address for the pnx15xx series spdif output port module is 0x10 9000. 5.1 register summary table 4: spdif out external signals signal type description spdo o spdif output. self clocking interface carrying either two-channel pcm data with samples up to 24 bits, or encoded dolby digital (ac-3) or mpeg audio data for decoding by an external ac3 or mpeg capable audio ampli?r. figure 3: suggested external spdif output interface circuitry 10 uf 240 ohm 110 ohm transformer 1:1 1.5 - 7 mhz rca phono spdo pnx15xx table 5: spdif output module register summary offset name description 0x10 9000 spdo_status spdif out status 0x10 9004 spdo_ctl spdif out general control register 0x10 9008 reserved 0x10 900c spdo_base1 base address of buffer1
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-9 remark: the clock frequency emitted by the dds output can be found in chapter 5 the cloc k module . 5.2 register table 0x10 9010 spdo_base2 base address of buffer2 0x10 9014 spdo_size size of the buffers 0x10 9018?ff0 reserved 0x10 9ff4 spdo_pwr_dwn powerdown 0x10 9ffc spdo_module_id module id table 5: spdif output module register summary ?ontinued offset name description table 6: spdo registers bit symbol acces s value description offset 0x10 9000 spdo_status 31:5 reserved to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 buf1_empty r 0 this ?g gets set if dma buffer 1 has been emptied by the spdo hardware. the ?g can be cleared only by a software write to ack_buf1. 1 buf2_empty r 0 this ?g gets set if dma buffer 2 has been emptied by the spdo hardware. the ?g can be cleared only by a software write to ack_buf2. 2 hbe (bandwidth error) r 0 bandwidth error. this ?g gets set if the internal buffers in spdo were emptied before new memory data was brought in. this ?g can be cleared only by a software write to ack_hbe. 3 underrun r 0 this ?g gets set if both dma buffers were emptied before a new full buffer was assigned by software. the hardware has performed a normal buffer switch over and is emitting old data. it can only be cleared by software write to ack_udr. 4 buf1_active r 1 this ?g gets set if the hardware is currently emitting dma buffer 1 data, and is negated when emitting dma buffer 2 data. offset 0x10 9004 spdo_ctl 31 reset w 0 1 =software reset. immediately resets the spdo block. this should be used with extreme caution. any ongoing transmission will be interrupted, and receivers may be left in a strange state. 30 trans_enable r/w 0 1 =enables transmission as per the selected mode. 0 =transmission disabled. stops any ongoing transmission after completing any actions related to the current data descriptor word.
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-10 29:27 trans_mode r/w 000 transmission mode. 000 =iec-60958 mode. hardware performs bi-phase mark encoding, preamble and parity generation, and transmits one iec-60958 subframe for each data descriptor word. 010 =transparent mode, lsb ?st. the 32 bit data descriptor words are transmitted as is, lsb ?st. 011 =transparent mode, msb ?st. the 32 bit data descriptor words are transmitted as is, msb ?st. other codes are reserved for future extensions. note: the transmission mode should only be changed while transmission is disabled. 26:8 reserved - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 7 udr_inten r/w 0 if udr_inten = 1 and underrun = 1, an interrupt is asserted to the chip level interrupt controller. 6 hbe_inten r/w 0 if hbe_inten = 1 and hbe = 1, an interrupt is asserted to the chip level interrupt controller. 5 buf2_inten r/w 0 if buf2_inten = 1 and buf2_empty = 1, an interrupt is asserted to the chip level interrupt controller. 4 buf1_inten r/w 0 if buf1_inten = 1 and buf1_empty = 1, an interrupt is asserted to the chip level interrupt controller. 3 ack_udr w 0 1= clear underrun. 0=no effect. always reads as 0. 2 ack_hbe w 0 1= clear hbe. 0= no effect.always reads as 0. 1 ack_buf2 w 0 1= clear buf2_empty. informs spdo that dma buffer 2 is full. 0= no effect. always reads as ?? spdo_base2 is then used to fetch buffer1 data from memory. 0 ack_buf1 w 0 1= clear buf1_empty. informs spdo that dma buffer 1 is 0= no effect. always reads as 0. spdo_base1 is then used to fetch buffer1 data from memory. offset 0x10 9008 reserved 31:0 reserved - r/w to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. offset 0x10 900c spdo_base1 31:6 spdo_base1 0x0 r/w contains the memory address of dma buffer 1. if changed it must be set before ack_buf1. 5:0 reserved - r to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. offset 0x10 9010 spdo_base2 31:6 spdo_base2 0x0- r/w contains the memory address of dma buffer 2. if changed it must be set before ack_buf2. 5:0 reserved - r to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. offset 0x10 9014 spdo_size table 6: spdo registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 17: spdif output 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 17-11 31:6 spdo_size 0x0 r/w determines the size, in bytes, of both dma buffers 5:0 reserved - r to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. offset 0x10 9018?ff0 reserved offset 0x10 9ff4 spdo_pwr_dwn 31:1 reserved - to ensure software backward compatibility unused or reserved bits must be written as zeros and ignored upon read. 0 pwr_dwn 0x0 r/w used to provide power control status for system software block power management. offset 0x10 9ffc spdo_module_id 31:16 id 0x0121 r module id. this ?ld identi?s the block as type spdo. id=0x0121 15:12 maj_rev 0 r major revision id. this ?ld is incremented by 1 when changes introduced in the block result in software incompatibility with the previous version of the block. first version default = 0 11:8 min_rev 0x1 r minor revision id. this ?ld is incremented by 1 when changes introduced in the block result in software compatibility with the previous version of the block. first version default = 0. 7:0 aperture 0 r aperture size. identi?s the mmio aperture size in units of 4 kb for the spdo block. spdo has an mmio aperture size of 4kb. aperture = 0: 4kb table 6: spdo registers ?ontinued bit symbol acces s value description
1. introduction the spdif input block accepts digital serial input that complies with the iec60958 format speci?ation for audio bitstreams. the interface locks onto and decodes the incoming ?iphase-mark?encoded signal and recognize all preambles associated with the iec60958 audio format. 1.1 features key functions include: clock extraction and decode of incoming ?iphase-mark?encoded serial bitstream recognition of all preamble types: b, m, w support for 17- to 24-bit pcm coded or non-pcm coded data types dma of incoming audio samples into memory raw mode 32-bit capture of incoming sub-frames interrupt on parity or validity error as well as others internal loopback with spdif out - diagnostic mode support for iec61937 non-pcm bitstreams format capture of channel status and user information to mmio registers 2. functional description 2.1 spdif input block level diagram the spdif high level block diagram is presented in figure 1 . the spdif receiver input samples the input bitstream at a much higher clock rate than the input source bitrate. during this process, the spdif bitclock and data are recovered. this sampled ?ynchronous audio stream is then passed to an spdif decoder function. internally, the spdif decoder produces a decoded binary representation of the ?i-phase?data stream. at its output, the decoder produces a framed audio data format with separate framing, data and clock signals. this framed audio data is fed to the dma unit for chapter 18: spdif input pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-2 storage in main memory using a hardware double buffered scheme. in addition, during the decode phase, the input stream is processed to extract parity, validity and selected channel status information for each iec60958 block. the spdif bitstream is composed of a single signal that is organized into a block structure of 192 frames. the signal has both data and an embedded clock present. each frame is composed of 2 subframes each composed of 32 bits. the stream is encoded with a line code called ?i-phase mark?encoding. figure 2 shows the organization of the iec60958 spdif stream format. the input stream is parsed by the hardware using an extracted bitclock that is synchronous to the oversampling clock. the audio data, validity ?g, channel status and parity bits are extracted and the spdi_status and spdi_cbits registers are updated, see figure 9 . the audio portion of each subframe can contain samples that are up to 24 bits in length. 2.2 architecture 2.2.1 functional modes the spdif input module has 3 major functional modes. all modes are con?ured via software programmable mmio registers, see figure 9 . these modes are: 16-bit mode : subframe bits [27:12] inclusive are selected and stored. all biphase encoded bits are decoded. in addition, the state of the parity bit and the validity bit of each subframe is sampled and the spdi_status register is updated with the results. this mode is useful when the stream contains either 16-bit pcm audio or 16-bit non-pcm samples. 32-bit mode : subframe bits [27:4] inclusive are selected and stored subject to a programmable bitmask. a 32-bit word is formed by padding ??bits to the least signi?ant end of the masked audio samples. in addition, the state of the parity bit and the validity bit of each subframe is sampled and the spdi_status register is updated with the results. this mode provides for any audio sample size ranging from 17 to 24 bits. figure 1: spdif input block diagram spdi_in spdif input 32 data spdif input pin oversampling clock domain mtl bus to external memory memory clock domain registers control dtl_mmio_clk domain dma unit
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-3 raw capture mode : subframe bits [31:0] inclusive are selected and stored. all ?iphase encoded bits are decoded and a binary representation of the iec60958 subframe is generated. the entire 32-bit binary number is then stored as one unit in memory. section 3.2 provides detailed information regarding use of all functional modes. 2.3 general operations 2.3.1 received serial format 2.3.2 memory formats the s/pdif input block will copy the incoming samples into memory in the order that they occur in the input bitstream. the input bitstream is parsed and audio samples are captured and packed as 32-bit words prior to being written to memory. the spdif input decoder always decodes the bi-phase encoded samples into binary prior to transfer to memory. refer to figure 4 for the memory formatting for each of the sample sizes supported by the spdif input module. 16-bit mode : the input samples are packed into 32-bit words consisting of two 16-bit samples per 32-bit word. this mode is compatible with the tm1100 and pnx2700 audio out memory formats. 32-bit mode : for 17 through 24-bit audio, the samples are formatted into 32-bit words and placed in memory at consecutive 32-bit addresses. for these sample sizes, the sample is ?st combined with a programmable bitmask figure 2: serial format of an iec60958 block channel 1 m channel 2 w channel 1 b channel 2 w channel 1 m channel 2 w start of block (indicated by unique b pre-amble) sub-frame sub-frame frame 0 frame 1 channel 1 m frame 191 0 31 28 24 20 16 12 8 4 sample data l s b m s b b, w or m pre-amble aux. vucp validity flag user data channel status parity bit sub-frame (2 channel pcm) 0 31 28 24 20 16 12 8 4 16 bits data l s b m s b b, w or m pre-amble vucp validity flag user data channel status parity bit sub-frame (non-pcm audio) unused (0)
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-4 spdi_smpmask.smask. the result of the mask operation is zero extended, at the least signi?ant end, to the full 32-bits before being placed in memory. the resultant 32 bit words are of the form: 0x nnnnmm 00 where the n s are the 16 msbits of the sample, the ms are the masked 8 lsbits subject to smask, see section 3.2.9 . this mode produces audio that is compatible with the pnx2700 audio out memory formats. raw capture mode : input subframes are captured and all ?i-phase?encoding (bits [4:31]) is replaced with a binary representation. the preamble portion (bits [0:3]) of the subframe is replaced with a code indicating what preamble was present, see figure 3 . all parts of the subframe are assembled in order and this 32-bit word is then placed in memory. this mode can be used for ?ass-through of audio to an external spdif out block. the external spdif out block must be con?ured appropriately. 2.3.3 spdif input endian mode the spdif input module can store data in memory using either big-endian or little- endian formatting. figure 3: spdif input: raw mode format 0 31 28 24 20 16 12 8 4 sample data l s b m s b b, w or m pre-amble aux. vucp ?i-phase?encoded binary 0 31 28 24 20 16 12 8 4 sample data l s b m s b code aux. vucp ?i-phase violations b preamble replaced with ?000 m preamble replaced with ?001 w preamble replaced with ?010 input iec subframe output raw mode subframe figure 4: spdif input sample order view of memory adr sd.left n adr+2 sd.right n+ adr+4 sd.left n+1 adr+6 sd.right n+1 adr+8 sd.left n+2 adr+10 sd.right n+2 adr+12 sd.left n+3 adr+14 sd.right n+3 16 bit format, 16-bit samples stereo 32 bit raw mode format subframe.left n adr subframe.right n adr+4 subframe.left n+1 adr+8 subframe.right n+1 adr+12 32 bit format, 18-24bit samples stereo sd.left n adr sd.right n adr+4 sd.left n+1 adr+8 sd.right n+1 adr+12
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-5 the format in memory for both little and big-endian byte ordering is shown in figure 5 2.3.4 bandwidth and latency requirements normally, the rate of transmission of frames corresponds exactly to the source sampling frequency. the maximum latency requirement will be for 96 khz streams (i.e. frame rate = 96 khz) with the spdif input input set up for any of the 32-bit capture modes: (96k frames/sec) x (8bytes/ frame) = 0.768mbytes/sec the maximum latency allowed in order to sustain this transfer rate is (assuming data transfers are 64 bytes each): 64 bytes/n sec= 0.768 mbytes/sec solving for n and providing a relation, (14) for error-free operation during sustained dma, there needs to be one 64 byte dma write transfer completed to memory every 83 usecs. this guarantees the latency requirement for the worst case input sample rate. if the latency requirement is not met, the hardware sets the hbe bit in the spdi_status register to logic ? indicating a bandwidth error. for this condition, one or more audio samples have been lost and are not recoverable. the bus arbitration for the spdif input input block should be adjusted by the user to satisfy this latency requirement. refer to section section 3.2 for details on spdi_status and other registers. figure 5: endian mode byte address memory format little endian 16-bit stereo etc. msbyte lsbyte l: left r: right note : n, n+1, n+2, n+3 refer n n+1 n+2 n+3 31 15 0 big endian 16-bit stereo etc. 31 15 0 or raw 32-bit stereo etc. n+3 31 0 little endian n n+7 n+4 31 0 or raw 32-bit stereo etc. 31 0 big endian 31 0 to increasing byte addresses within a naturally aligned 32-bit memory address. (i.e. n = 0x0, 0x4, 0x8,0xc, etc.) n n+1 n+2 n+3 msbyte lsbyte msbyte lsbyte msbyte lsbyte msbyte lsbyte l r l r r l r l msbyte lsbyte lsbyte msbyte lsbyte msbyte n+3 n n+7 n+4 n 83.33usec
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-6 3. operation 3.1 clock programming 3.1.1 spdif input clock domains the spdif input module operates using two clock domains. from figure 1 , the spdif receiver, decoder and dma unit use an oversampling clock. the oversampling clock frequency is software selectable via the chip central clocking function. the registers blocks use a dtl_mmio clock and resynchronize whats needed into spdif receiver oversampling clock the source input stream is oversampled by the spdif receiver and a representation of the bi-phase data bitstream is produced along with a separate internal 64 fs bitclock. the oversampling clock used to sample the input stream is a low jitter, divided form of the system pll clock. the frequency of the oversampling clock must be within a certain frequency range described by the following equation . (15) where fs is the incoming sample rate. factors affecting this frequency range are beyond the scope of this document. to guarantee error free capture for all sample rates, the oversampling frequency fosclk must be set to a nominal value. the spdif receivers?internal oversampling clock frequency can be programmed by selecting a clock divider setting in the central clock functional block (see chapter 5 the cloc k module for oversampling clock programming details). the divider selections and clocks that are produced are shown in t ab le 1 . 3.1.2 spdif receiver sample rate tolerance and iec60958 three levels of sampling frequency accuracy are speci?d in the iec60958 document. the spdif receiver will achieve lock onto a level iii signal ( variable pitch shift of +/- 12.5% of fs ) with respect to all the standard sampling frequencies; 32 khz, 44.1 khz and 48 khz as well as the higher 96 khz. for this design, the spdif receiver is classi?d as a level iii compliant receiver. 3.1.3 spdif input receiver jitter tolerance the maximum tolerable input jitter of the spdif input receiver is described by the equation (16) table 1: spdif input oversampling clock value settings input audio sample rate: fs (khz) central pll base frequency (64x27 mhz)/4 central clock divider n fosclk: oversampling clock freq (mhz) 96 432 mhz 3 144.00 32.0, 44.1 and 48.0 432 mhz 6 72.0 1220fs fosclk 2400fs ? t max jitter () 0.13 1 128f s ----------- --- - ? =
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-7 or 0.26ui pk-pk (1 ui = 1/128 fs ). for a particular fs , the max jitter is shown in t ab le 2 . the spdif input receiver will reproduce the input data and clock without error if the maximum input jitter remains within the speci?d max jitter tolerance above. the receiver design meets and exceeds the iec60958-3 consumer jitter requirements speci?ation (i.e 0.25 ui pk-pk between 200 hz and 400 khz jitter freq. ). 3.1.4 spdif input and the oversampling clock the oversampling clock supplied to the input receiver is derived from a divider in the central clock control block. the divider value to select is determined by t ab le 1 . once the oversampling clock has been selected by programming a divider value, the condition of the lock bit status indicator in spdi_status provides feedback on whether the selected oversampling clock has allowed the interface to achieve lock onto the incoming spdif input stream. the settings provided by the divider for the oversampling clock are suf?ient for capture of 32 khz, 44.1 khz, 48 khz and 96 khz sample rate input streams. 3.2 register programming guidelines 3.2.1 spdif input register set the s/pdif register set is outlined in figure 9 on page 18- 15 and figure 10 on page 18- 16 . the register set is composed of status and control functions necessary to con?ure spdif input data capture and dma of audio data to main memory. to ensure compatibility with future devices, any reserved mmio register bits in figure 9 and figure 10 should be ignored when read, and written as zeroes . table 2: input jitter for different sample rates fs (khz) 1 ui = 1/(128 fs) (nsec) max jitter = 0.26ui pk-pk (nsec) 32 244.1 31.7 44.1 177.2 23.0 48 162.8 21.2 96 81.4 10.6 figure 6: spdif input oversampling clock generation divide by n 432mhz (16x27mhz) pin spdi_in central clocking domain n = 3, 6 spdif input domain spdif input receiver spdif input decoder memory bound audio data oversampling clock
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-8 3.2.2 spdi_status register functions the ucbits bit indicates that a complete set of user data and channel status bits is available in the spdi_cbitsx and spdi_ubitsx registers. this bit is updated on a block basis. the lock bit indicates whether the interface has locked onto the incoming spdif stream. software must detect the lock condition asserted before enabling data capture. the lock bit is active as long as an oversampling clock is supplied. capture does not have to be enabled for the lock bit to be active. the unlock bit indicates that the receiver has either: 1) not attained the locked state -or- 2) has fallen out of the locked state for some reason. at power on, the interface will indicate that it is not locked by asserting the unlock status bit. during normal operation, when a valid spdif input stream is applied to the pin interface, the receiver will indicate a lock condition is attained by asserting the lock bit. if the receiver then looses lock, the unlock bit will be asserted. each of the unlock and lock status bits can be used to generate an interrupt to the system. note that the lock and unlock status bits are sticky, meaning that once they are set in the status register, each must be cleared explicitly by writing to the appropriate bit in the spdi_intclr register. the verr and perr bits indicate validity and parity error conditions associated with the data contained within the input stream. note that when validity errors occur, the associated payload data is passed unchanged. when parity errors occur, the associated payload data is muted (zeroed). this conditions apply to all modes except raw mode capture. for raw mode, the entire decoded subframe is passed to memory regardless of parity. overrun and hbe indicate data loss conditions in memory and internally to the hardware. buf1_active indicates whether memory buffer 1 is currently being ?led with data. buf1_full and buf2_full indicate whether memory buffers are completely used. refer to t ab le 6 for more details. 3.2.3 lock and unlock state behavior shortly after power on (or any reset), the receiver will indicate that it is not locked to an input stream by asserting the unlock bit in spdi_status. later, once a valid spdif input stream is applied to the interface, the receiver will assert the lock status bit. at this moment, the receiver has determined that the input stream is valid and that dma capture can be started by the user. note that these two status bits, lock and unlock are sticky and may become activated regardless of the state of the spdif input capture enable bit spdi_ctl.cap_enable. software must explicitly clear the lock and unlock status bits using the appropriate spdi_intclr register bits. the spdif input receiver will never be in a locked state and in an unlocked state simultaneously. also note that the lock and unlock behavior applies to all capture modes. for raw mode processing, parity and validity bits are ignored. perr or verr status bits are not updated. 3.2.4 unlock error behavior and dma if the receiver should encounter an error condition in the stream, it will indicate this by asserting the unlock bit. during runtime, the conditions that can cause the unlock state are: 1) an unexpected bi-phase error is encountered; 2) the input
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-9 stream is not present or is suddenly removed, and 3) the input signal contains too much jitter. if the unlock_enbl bit is set, the spdif input will generate an interrupt. note that parity and validity errors (perr and verr) do not cause out of lock conditions. from the point where the error condition occurred, the contents of the currently ?ling internal 64 byte buffers are muted (zeroed). the external memory buffers will receive muted data from this point forward. if the receiver does not re-lock before the current external memory buffer is ?led to completion with muted data, dma will halt. dma is halted in this way so that bus resources are not further utilized. otherwise, dma continues with valid data soon after lock is reacquired. from the error point onward, the last stable capture sample rate will be maintained by the hardware automatically during this error condition processing. the following is a start-up software process ?w for capture of an spdif stream. 3.2.5 spdi_ctl and functions the spdi_ctl register provides system control of the spdif input interface. the reset bit is used to completely reset the interface and all registers. the result of asserting the reset bit is all spdif input capture activity stops and all registers are initialized to logic ?s. in addition, any pending spdif input interrupts are cleared and disabled. any pending dma activity is cancelled and active request are aborted. figure 7: lock/unlock processing for spdif input service unlock interrupt disable unlock interrupt enable lock interrupt disable capture and/or reset (optional) con?ure spdif input regis- ters as necessary. enable lock interrupt disable unlock interrupt service lock interrupt disable lock interrupt enable unlock interrupt enable capture no no unlock indicator auto asserted by receiver wait a user defined amount of time - then increase oversampling clock to achieve lock. yes - lock interrupt generated lock indicator active? unlock indicator active? normal audio processing yes - unlock interrupt generated power on/hw reset/sw reset
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-10 the cap_enable and samp_mode bits enable capture of audio data in a particular format as described in t ab le 6 on page 18- 17 and section 2.3.2 . the chan_mode bits allow capture in either stereo (left/right sample pairs) or mono (primary or secondary channel). the chan_mode setting is independent of the ucbits_sel setting. the diag_mode bit is used in conjunction with an spdif out block. the diag_mode bit con?ures the spdif input source to be the output pin of the spdif out block. programmers must con?ure spdif input and spdif output modules appropriately to use the loopback properly. the memory formats used while this bit is enabled are unaffected. the only difference is that the source of the input stream is internal rather that the external spdif input pin. 3.2.6 spdi_cbitsx and channel status bits the channel status block indicates the status of the currently received audio stream. its structure is different for each of the consumer or professional iec60958 formats. within each 32-bit subframe is a channel status bit at location bit[30] in the 32-bit word. the two ? bits, one for each of the subframes within a frame, can be different. this can occur, for instance, while receiving a 2-channel stream. spdi_cbits1..spdi_cbits6 hold channel status bits embedded in the source spdif stream. the spdi_cbitsx registers are updated on a block basis. upon the occurrence of each new b preamble in the source stream, the spdi_cbitsx registers are updated with selected channel status information from the previous block. programmers can use the spdi_cbitsx registers to determine the state of the spdif source material. information such as whether the stream is a consumer or professional type, sample rate and sample size can be determined as well as other information. the spdi_ctl.ucbits_sel register determines which set (subframe 1 or 2) of 192 channel status bits will be captured. a selected set of the channel status bits captured by the spdi_cbits registers are shown in t ab le 3 and t ab le 4 . table 3: spdi_cbits1 channel status meaning spdi_cbits1[n] iec consumer channel status bit no. iec consumer meaning aes/ebu professional channel status bit no. aes/ebu professional meaning 0 0 consumer mode 0 professional mode 1 1 pcm/non-pcm data 1 pcm/non-pcm data 2 2 copyright 2 emphasis 3 3 format 3 emphasis 4 4 format 4 emphasis 5 5 format 5 locked 6 6 mode 6 sample rate 7 7 mode 7 sample rate 8 8 category code 8 channel mode 9 9 category code 9 channel mode 10 10 category code 10 channel mode 11 11 category code 11 channel mode
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-11 3.2.7 spdi_ubitsx and user bits the complete set of user data channel bits are available in the spdi_ubitsx registers. the spdi_ubitsx registers are updated on a block basis. upon the occurrence of each new b preamble in the source stream, the spdi_ubitsx 12 12 category code 12 user bit mgmt 13 13 category code 13 user bit mgmt 14 14 category code 14 user bit mgmt 15 15 category code 15 user bit mgmt 16 16 source number 16 use of aux bits 17 17 source number 17 use of aux bits 18 18 source number 18 use of aux bits 19 19 source number 19 source word length - source encode history 20 20 channel number 20 source word length - source encode history 21 21 channel number 21 source word length - source encode history 22 22 channel number 22 source word length - source encode history 23 23 channel number 23 source word length - source encode history 24 24 sample rate 24 multi-channel function 25 25 sample rate 25 multi-channel function 26 26 sample rate 26 multi-channel function 27 27 sample rate 27 multi-channel function 28 28 clock accuracy 28 multi-channel function 29 29 clock accuracy 29 multi-channel function 30 30 reserved 30 multi-channel function 31 31 reserved 31 multi-channel function table 4: spdi_cbits2 channel status meaning spdi_cbits2[n] iec consumer channel status bit no. iec consumer meaning aes/ebu professional channel status bit no. aes/ebu professional meaning 0 32 word length 32 digital audio reference signal 1 33 word length 33 digital audio reference signal 2 34 word length 34 reserved 3 35 word length 35 reserved 4:31 36:63 36:63 table 3: spdi_cbits1 channel status meaning ?ontinued spdi_cbits1[n] iec consumer channel status bit no. iec consumer meaning aes/ebu professional channel status bit no. aes/ebu professional meaning
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-12 registers are updated with user data bits information from the previous block. the meaning of the user data is application dependent. the spdi_ctl.ucbits_sel register determines which set (subframe 1 or 2) of 192 user data bits will be captured. 3.2.8 spdi_basex and spdi_size registers and memory buffers spdi_base1 and spdi_base2 are used to select the main memory buffer starting addresses used for dma of audio data samples. at the start of spdif input capture, the hardware will begin ?ling the memory buffer beginning at the address speci?d in the spdi_base1 register. once this buffer is ?led, the hardware will switch buffers and begin ?ling the memory buffer starting at the address speci?d in the spdi_base2 register. the size of these dma buffers is speci?d in the spdi_size register. note that the hardware limits the buffer size and starting address to be aligned to 64 byte addresses. assignment to spdi_base1, spdi_base2 and spdi_size have no effect on the state of the spdi_status ?gs. any change to the spdi_base1 or spdi_base2 registers should only be done while a memory buffer is not being used by the hardware dma. 3.2.9 spdi_smpmask and sample size masking the spdi_smpmask register allows per bit masking the least signi?ant 8 bits of the incoming samples (corresponding to subframe bits [11:4]). the smask setting only applies to 32-bit capture mode (i.e. samp_mode = 01). the 8 bits of smask will determine which subframe bits [11:4] will be captured and stored in memory. to reject a particular bit ( within subframe bits [11:4] ) in an audio sample, set the corresponding smask[7:0] bit to logic ?? the default value of smask is 0x00. note the sense of the mask operation! setting smask[7:0] bits to logic ??will zero the corresponding subframe bit [11:4]. others will pass unchanged! ex 1. the capture mode is con?ured for 32-bit stereo capture (samp_mode = 01 and chan_mode = 00). it is desired to store only 20 bit sample pairs. the left/right channels incoming subframe bits [27:4] consist of a 24 bit samples of the form l = 0xabcdef and r = 0x123456 respectively. to retain the most signi?ant 20 bits (i.e. keep ?bcde?in the left sample and ?2345?in the right sample) and write them to memory, set the smask[7:0] bits to ?x0f? during capture and once the samples are masked, the least signi?ant ends are zero extended to 32 bits. the result is a 32 bit sample pair of the form l = ?xabcde000?and r = ?x12345000? the samples are ?ally stored in memory subject to endian control. the masking operation applies to all memory bound samples. 3.2.10 spdi_bptr and the start of an iec60958 block during spdif input capture, memory buffers are continuously ?led with input data. as input blocks are ?ling the memory buffers, the address of the ?st instance of a frame 0 in a particular memory buffer changes continuously. to aid software with the task of ?ding the start of a block in memory, the spdi_bptr contains the address of the ?st occurrence of a frame 0 (indicating the starting boundary of a complete 192 frame block) within the last ?led memory buffer - either buf1 or buf2. this function is useful during capture of non-pcm coded data as found in iec61937 data streams. the software driver can use spdi_bptr to ?d the beginning of an iec60958 block and then quickly determine the location of any sync condition thereafter embedded in the non-pcm data structure.
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-13 3.2.11 interrupts the spdi_status register contains status ?gs that indicate certain conditions that may need the attention of the chip level controller. each of these conditions can be used as interrupt sources. the spdi_inten register is used to provide the capability to enable any of the interrupt source bits in the spdi_status register. to enable one of the interrupts shown in the spdi_status register, the programmer must set the corresponding spdi_inten bits for that interrupt source. for example, to allow an interrupt to be passed to the chip level interrupt controller upon the occurrence of a parity error in the incoming stream during capture, the user must write a logic ??to the perr_enbl bit in spdi_inten. to disable an interrupt source, write a logic ??to the appropriate bit in spdi_inten. the effect of writing a logic ??to an enable bit while the particular interrupt is active is that the interrupt is unconditionally de- asserted and disabled. the status conditions in the spdi_status register will be ?ticky? meaning the spdi_status bit will remain active until explicitly cleared by setting the corresponding clear bit in the spdi_intclr register. using the same example above, if the parity error bit perr is enabled (spdi_inten.perr_enbl = 1) and the perr interrupt is active currently, to clear the perr bit and deactivate the interrupt the user must write a logic ??to the perr_clr bit in the spdi_intclr register. the spdi_intset register is useful for software diagnostic generation of interrupts. setting any of these bits to logic ? will generate an interrupt to the chip level interrupt controller. to use the spdi_intset register to generate interrupts, the same enable rule applies as outlined above. for spdif input, the hardware interrupt signal is ?evel triggered? this means the interrupt signal passed to the chip level interrupt controller will be logic ? when active and will remain so until cleared explicitly by the system interrupt handler software. 3.2.12 event timestamping spdif input has no timestamping internal to the block. instead, spdif input exports several event noti?ation signals to the central timestamping function on chip, see chapter 8 gener al pur pose input output pins and section 8.1 on page 3- 27 in chapter 3 system on chip resources . the central timestamp function includes timers and timestamp registers to provide event counts and event triggered ?napshot clock values. the event signal is a positive edge going pulse with positive level duration greater than or equal to 160 ns. the speci? events that are exported to the central timestamp function are: ws (word strobe) - this event signals the arrival of a sample pair on the spdif input interface. the rising edge of the signal indicates the beginning of either the b or m subframe. the logic ?igh?duration is as stated above.
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-14 sws (last subframe) - this event signal indicates that a single 32-bit subframe corresponding to the last sample in the currently ?ling memory buffer has been received at the input to spdif input. the event is not quali?d with a particular block boundary. this represents a precise, periodic event for use by system software to achieve audio/video synchronization. all spdi_status register bits (except lock) - these events can be used by software to either count or timestamp any interrupt generated by spdif input. refer to t ab le 6 for details regarding spdif input interrupt sources. 4. signal descriptions 4.1 external interface pins the spdif input module has a single input pin. the signal applied to this pin must have ttl level voltage swing. for the commonly found 0.5 vpp spdif signal (iec60958 consumer mode), the user must externally restore the signal to ttl voltage levels. in all cases, external isolation of the input signal is recommended. 4.1.1 system interface requirements iec60958 speci?s that consumer systems have a 0.5 vpp signal driven from the transmitter into an unbalanced cable with a 75 ohm nominal impedance. the load side must present a 75-ohm resistive impedance over the frequency band of 0.1 to 6 mhz. figure 8 presents an input circuit that satis?s the load requirements. the circuit presents a simple rs422 differential receiver. the chosen receiver should have good input hysteresis. also, the signal applied to the spdif input input pin should ideally have a 50% duty cycle. it is recommended that the system designer add an isolation transformer to the input circuit. other consumer input circuits may be possible. table 5: spdif input pin summary signal type description spdi_in in single-ended spdif input pin. input sample rate can be 32 khz, 44.1 khz, 48 khz or 96 khz. input signal must be ttl compatible. figure 8: spdif input consumer interface spdif input rca 0v vdd phono +v -v + - rs-422 receiver ttl output with good input hysteresis differential voltage swing is 0.5vpp 75 ohm 0v need 50% duty cycle
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-15 5. register descriptions 5.1 register summary 5.1.1 spdif input interrupt registers the registers spdi_status, spdi_intset, spdi_intclr and spdi_inten support dvp block level interrupt processing. the spdif input interrupt control mechanism is discussed in detail in section section 3.2.11 . figure 9: spdif input mmio registers (1 of 2) address offset: spdi_ctl (r/w) 0x000 reset cap_enable samp_mode[1:0] diag_mode ucbits_sel chan_mode[1:0] spdi_base1 (r/w) 0x004 spdi_base2 (r/w) 0x008 base2 spdi_size (r/w) 0x00c size (in bytes) base1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 spdi_cbits1 (r/o) 0x018 cbits[31:0] 31 0 3 7 11 15 19 23 27 spdi_bptr (r/o) 0x010 address spdi_cbits6 (r/o) 0x02c cbits[191:159] spdi_ubits1 (r/o) 0x030 ubits[31:0] spdi_ubits6 (r/o) 0x044 ubits[191:159] 6 registers total 6 registers total spdi_smpmask (r/w) 0x014 smask gl-filter[3:0]
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-16 figure 10: spdif input mmio registers (2 of 2) spdi_module_id (r/o) (pio) 0xffc spdi_pwr_dwn (r/w) (pio) 0xff4 pwr_dwn id = 0x0110 maj_rev min_rev aperture spdi_status (r/o) 0xfe0 buf1_active overrun hbe (bandwidth error) buf2_full buf1_full perr verr lock 31 0 3 7 11 15 19 23 27 spdi_intclr (w/o) 0xfe8 spdi_intset (w/o) 0xfec buf1_active_set ovr_set hbe_set buf2_full_set buf1_full_set perr_set verr_set lock_set buf1_active_clr ovr_clr hbe_clr buf2_full_clr buf1_full_clr perr_clr verr_clr lock_clr spdi_inten (r/w) 0xfe4 buf1_active_enbl ovr_enbl hbe_enbl buf2_full_enbl buf1_full_enbl perr_enbl verr_enbl lock_enbl ucbits ucbits_enbl ucbits_clr ucbits_set unlock unlock_enbl unlock_clr unlock_set
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-17 5.2 register table table 6: spdif input registers bit symbol acces s value description offset 0x10 a000 spdi_ctl 31:9 unused - 11:8 gl_filter r/w 0 input glitch ?ter control. these bits control the rejection of a glitch on the spdi interface. 0000 = the glitch rejection filter is disabled. 0001 .. 1111 = an incoming signal transition must remain stable for (programmed value + 1) rising edges of osc_clk, otherwise it is rejected as a glitch. 7 ucbits_sel r/w 0 user/channel status bits select. selects the set of subframes from which the user and channel status bits are extracted and written to the spdi_ubitsx and spdi_cbitsx registers. this bit is activated only on a block boundary, meaning that the bit can be changed at any time via software, but the update of the spdi_ubitsx and spdi_cbitsx registers with the new information will wait until a complete block has been received at the spdif input. 0 = subframe 1 is selected, user and channel status bits are extracted/written to ubitsx and cbitsx registers. 1 = subframe 2 is selected. user and channel status bits are extracted/written to ubitsx and cbitsx registers. 6:5 chan_mode[1:0] r/w 0 00 = capture stereo left/right sample pairs (default). 01 = capture mono primary (subframe 1) channel. 10 = capture mono secondary (subframe 2) channel. 11 = reserved note: the channel mode should only be changed while capture is disabled (i.e. cap_enable = 0). 4:3 samp_mode[1:0] r/w 0 00 = 16-bit mode . subframe bits [27:12] inclusive are selected and stored. hardware stores a single 16-bit word per subframe. if audio samples are actually larger than 16 bits, the most signi?ant 16 bits of the audio sample will be selected and stored. 01= 32-bit mode . subframe bits [27:4] inclusive are selected and stored subject to smask. a 32-bit word is formed by bitwise masking the sample (subject to the value of spdi_smpmask.smask) and padding ??bits to the least signi?ant end of the 24 bits. the resultant 32-bit words are of the form: 0xnnnnmm00 where the n s are the 16 subframe bits [27:12] and the m s are the eight masked subframe bits [11:4]. this provides for any audio sample size from 17 to 24 bits. (see the spdi_smpmask register description for operation of the smask feature). smask only applies for this sample mode. 10 = raw capture mode . the entire subframe is captured and stored. the bi-phase portion of the subframe (i.e., bits [31:4]) are decoded into binary. bits [3:0] are replaced with a code. the entire 32 bits are then stored as one unit. 11 = reserved note: the sample mode should only be changed while capture is disabled (i.e., cap_enable = ??.
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-18 2 diag_mode r/w 0 diagnostic loopback mode. used to diagnose the spdif input module. 0 = the spdif input source is set to the spdif input input pin (default). 1 = the spdif input source is set to the spdif out pin. 1 cap_enable r/w 0 writing a ??to this bit enables capture per the selected mode. writing a ??here stops any ongoing capture after completing any actions related to the current audio sample. 0 reset r/w 0 writing a ??to this bit resets the spdi block. the registers of the spdi will all be reset to ?s? this should be used with caution. any ongoing capture will be interrupted. offset 0x10 a004 spdi_base1 31:6 base1 r/w 0 selects the main memory buffer starting addresses used for dma of audio data samples. note: any change to the spdi_base1 register should only be done while a memory buffer is not being used by the hardware dma. if changed it must be set before buf1_full_clr. 5:0 reserved r 0 offset 0x10 a008 spdi_base2 31:6 base2 r/w 0 selects the main memory buffer starting addresses used for dma of audio data samples. note: any change to the spdi_base2 register should only be done while a memory buffer is not being used by the hardware dma. if changed it must be set before buf2_full_clr. 5:0 reserved r 0 hardwired to logic ? offset 0x10 a00c spdi_size 31:6 size (in bytes) r/w 0 the size of the dma buffers is speci?d in the spdi_size register. note hardware limits the buffer size and starting address to be aligned to 64-byte addresses. assignment to spdi_base1, spdi_base2 and spdi_size have no effect on the state of the spdi_status ?gs. 5:0 reserved r 0 hardwired to logic ? offset 0x10 a010 spdi_bptr 31:0 address r 0 to aid software with ?ding the start of a block in memory, the spdi_bptr contains the address of the ?st occurrence of a frame 0 (indicating the starting boundary of a complete 192-frame block) within the currently ?ling memory buffer: buf1 or buf2. this is useful during capture of non-pcm coded data found in iec61937 data streams. offset 0x10 a014 spdi_smpmask 31:8 unused - table 6: spdif input registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-19 7:0 smask r/w 0x00 allows per bitmasking the least signi?ant 8 bits of the incoming samples (corresponding to subframe bits [11:4]). the smask setting only applies to 32-bit capture mode (i.e., samp_mode = 01). the 8 bits of smask will determine which subframe bits [11:4] will be captured and stored in memory. note: setting smask[7:0] bits to logic ??will zero the corresponding subframe bit [11:4]. others will pass unchanged. spdi_cbitsx registers the spdi_cbitsx registers contain the current block channel status bits. the meaning of each of the channel status ?lds can change depending upon whether the input source is a consumer or professional bitstream. offset 0x10 a018 spdi_cbits1 31:0 cbits [31:0] r 0 channel status register 1 contains bytes 0, 1, 2 and 3 of the current channel status block according to spdi_ctl.ucbits_sel. it will always re?ct the condition of the current decoded block of 192 frames and will always start at the block boundary. register bit meaning will depend upon the source transmission (i.e., consumer vs. professional). see t ab le 3 for more details. offset 0x10 a01c spdi_cbits2 31:0 cbits [31:0] r 0 channel status register 2 contains bytes 4, 5, 6 and 7 of the current channel status block according to spdi_ctl.ucbits_sel. see t ab le 4 for more details. offset 0x10 a020 spdi_cbits3 31:0 cbits [31:0] r 0 channel status register 3 contains bytes 8, 9,10 and 11 of the current channel status block according to spdi_ctl.ucbits_sel. offset 0x10 a024 spdi_cbits4 31:0 cbits [31:0] r 0 channel status register 4 contains bytes 12, 13, 14 and 15 of the current channel status block according to spdi_ctl.ucbits_sel. offset 0x10 a028 spdi_cbits5 31:0 cbits [31:0] r 0 channel status register 5 contains bytes 16,17,18 and 19 of the current channel status block according to spdi_ctl.ucbits_sel. offset 0x10 a02c spdi_cbits6 31:0 cbits [191:159] r 0 channel status register 6 contains bytes 20, 21, 22 and 23 of the current channel status block according to spdi_ctl.ucbits_sel. spdi_ubitsx registers the spdi_ubitsx registers contain the current block user data channel bits. the meaning of each of the user data ?lds is dependent upon the application. offset 0x10 a030 spdi_ubits1 31:0 ubits [31:0] r 0 user bit 1 contains the state of user bytes 0,1, 2 and 3 of the block according to spdi_ctl.ucbits_sel. the spdi_ubits register will always re?ct the condition of the current decoded block of 192 frames. register bit meaning will depend upon the source transmission. table 6: spdif input registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-20 offset 0x10 a034 spdi_ubits2 31:0 ubits [31:0] r 0 user bit 2 contains the state of user bytes 4, 5, 6 and 7 of the block according to spdi_ctl.ucbits_sel. the spdi_ubits register will always re?ct the condition of the current decoded block of 192 frames. register bit meaning will depend upon the source transmission. offset 0x10 a038 spdi_ubits3 31:0 ubits [31:0] r 0 user bit 3 contains the state of user bytes 8, 9, 10 and 11 of the block according to spdi_ctl.ucbits_sel. the spdi_ubits register will always re?ct the condition of the current decoded block of 192 frames. register bit meaning will depend upon the source transmission. offset 0x10 a03c spdi_ubits4 31:0 ubits [31:0] r 0 user bit 4 contains the state of user bytes 12, 13, 14 and 15 of the block according to spdi_ctl.ucbits_sel. the spdi_ubits register will always re?ct the condition of the current decoded block of 192 frames. register bit meaning will depend upon the source transmission. offset 0x10 a040 spdi_ubits5 31:0 ubits [31:0] r 0 user bit 5 contains the state of user bytes 16, 17, 18 and 19 of the block according to spdi_ctl.ucbits_sel. the spdi_ubits register will always re?ct the condition of the current decoded block of 192 frames. register bit meaning will depend upon the source transmission. offset 0x10 a044 spdi_ubits6 31:0 ubits [191:159] r 0 user bit 6 contains the state of user bytes 20, 21, 22 and 23 of the block according to spdi_ctl.ucbits_sel. the spdi_ubits register will always re?ct the condition of the current decoded block of 192 frames. register bit meaning will depend upon the source transmission. offset 0x10 a048?fdc reserved offset 0x10 afe0 spdi_status 31:10 unused - 9 unlock r 0 unlock active. this ?g gets set to logic ??if the spdif input receiver is not locked onto an incoming stream. programmers can use this unlock indication, in conjunction with the lock bit, to determine the state of the receiver or to make a decision to adjust the oversampling frequency. see the de?ition of the lock bit. possible causes of an out-of-lock state are: i) the oversampling frequency is too high or too low with respect to the applied input spdif sample rate. ii) too much jitter in spdif input stream. iii) absent, invalid or corrupted spdif stream applied to the interface/receiver. the ?g can be cleared by a software write to unlock_clr. 8 ucbits r 0 user/channel bits available. this ?g is set if a new set of user data bits and channel status bits have been written to the spdi_ubitsx and spdi_cbitsx registers. updated on a block basis. table 6: spdif input registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-21 7 lock r 0 lock active 1 = the spdif input receiver achieved lock onto the incoming stream. use this lock ?g, in conjunction with the unlock ?g, to determine the state of the receiver or to make a decision to adjust the oversampling frequency. the ?g can be cleared by a software write to lock_clr. lock means that the internal pll is locked. a valid sequence of preambles is not required for lock. 6 verr r 0 validity error 1 = the hardware encounters a subframe that has the validity ?g set to 1, indicating that the payload portion of the subframe is not reliable. the ?g can be cleared by a software write to verr_clr. 5 perr r 0 parity error 1 = the hardware encounters a subframe that has a parity error. parity is even for the subframe and applies to subframe bits [31:4] inclusive. normally, the external spdif input transmitter will set the subframe p bit to logic ? or logic ? so that bits [31:4] have an even number of logic ?s and ?s? the ?g can be cleared by a software write to perr_clr. 4 overrun r 0 1 = both external main memory dma buffers are ?led before a new empty buffer is assigned by the system control cpu. hardware has performed a normal buffer switch over and is overwriting fresh, unconsumed data. this ?g can be cleared by software write to ovr_clr. 3 hbe (bandwidth error) r 0 bandwidth error 1 = the internal hardware dma buffers in spdi are full and at least one of them was not emptied before new input data arrived on the spdi interface, indicating that dma service latency is too long. this ?g can be cleared by a software write to hbe_clr. 2 buf1_active r 0 this ?g is set to logic ??if the hardware is currently ?ling memory dma buffer 1. otherwise, it is reset to logic ?? this ?g can be cleared by a software write to buf1_active_clr. 1 buf2_full r 0 this ?g is set to logic ? if memory dma buffer 2 has been ?led by the spdi hardware. it can be cleared by a software write to buf2_full_clr. 0 buf1_full r 0 this ?g is set to logic ? if memory dma buffer 1 has been ?led by the spdi hardware. it can be cleared by a software write to buf1_full_clr. offset 0x10 afe4 spdi_inten 31:10 unused - 9 unlock_enbl r/w 0 1 = unlock bit in spdi_status is enabled for interrupts. 0 = unlock bit in spdi_status is disabled for interrupts. 8 ucbits_enbl r/w 0 1 = ucbits bit in spdi_status is enabled for interrupts. 0 = ucbits bit in spdi_status is disabled for interrupts. 7 lock_enbl r/w 0 1 = lock bit in spdi_status is enabled for interrupts. 0 = lock bit in spdi_status is disabled for interrupts. 6 verr_enbl r/w 0 1 = verr bit in spdi_status is enabled for interrupts. 0 = verr bit in spdi_status is disabled for interrupts. table 6: spdif input registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-22 5 perr_enbl r/w 0 1 = perr bit in spdi_status is enabled for interrupts. 0 = perr bit in spdi_status is disabled for interrupts. 4 ovr_enbl r/w 0 1 = overrun bit in spdi_status is enabled for interrupts. 0 = overrun bit in spdi_status is disabled for interrupts. 3 hbe_enbl r/w 0 1 = hbe bit in spdi_status is enabled for interrupts. 0 = hbe bit in spdi_status is disabled for interrupts. 2 buf1_active_enbl r/w 0 1 = buf1_active bit in spdi_status is enabled for interrupts. 0 = buf1_active bit in spdi_status is disabled for interrupts. 1 buf2_full_enbl r/w 0 1 = buf2_full bit in spdi_status is enabled for interrupts. 0 = buf2_full bit in spdi_status is disabled for interrupts. 0 buf1_full_enbl r/w 0 1 = buf1_full bit in spdi_status is enabled for interrupts. 0 = buf1_full bit in spdi_status is disabled for interrupts. offset 0x10 afe8 spdi_intclr 31:10 unused - 9 unlock_clr r/w 0 1 = clear unlock bit in spdi_status. 0 = no effect 8 ucbits_clr w 0 1 = clear ucbits in spdi_status. 0 = no effect. 7 lock_clr w 0 1 = clears lock in spdi_status. 0 = no effect. 6 verr_clr w 0 1 = clear verr in spdi_status. 0 = no effect 5 perr_clr w 0 1 = clear perr in spdi_status. 0 = no effect. 4 ovr_clr w 0 1 = clear overrun in spdi_status. 0 = no effect. 3 hbe_clr w 0 1 = clear hbe in spdi_status. 0 = no effect. 2 buf1_active_clr w 0 1 = clear buf1_active in spdi_status. 0 = no effect. 1 buf2_full_clr w 0 1 = clear buf2_full in spdi_status. 0 = no effect. spdi_base1 must be valid before setting buf2_full_clr. 0 buf1_full_clr w 0 1 = clear buf1_full in spdi_status. 0 = no effect. spdi_base1 must be valid before setting buf1_full_clr. offset 0x10 afec spdi_intset 31:10 unused - 9 unlock_set w 0 1 = unlock bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect table 6: spdif input registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 18: spdif input 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 18-23 8 ucbits_set w 0 1 = ucbits bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 7 lock_set w 0 1 = lock bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 6 verr_set w 0 1 = verr bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 5 perr_set w 0 1 = perr bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 4 ovr_set w 0 1 = overrun bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 3 hbe_set w 0 1 = hbe bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 2 buf1_active_set w 0 1 = buf1_active bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 1 buf2_full_set w 0 1 = buf2_full bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect 0 buf1_full_set w 0 1 = buf1_full bit in spdi_status is to be set to logic ?? level trigger interrupt will be raised to the external interrupt controller if the corresponding enable bit is set to logic ?? 0 = no effect offset 0x10 aff4 spdi_pwr_dwn 31:1 unused - 0 pwr_dwn r/w 0 the bit is used to provide power control status for system software block power management. the pwr_dwn register is provided for software use only. the pwr_dwn bit has no functionality internal to the spdi input module. the bit is used to provide power control status for system software block power management. the default power on state of this bit is logic ?? offset 0x10 affc spdi_module_id 31:16 module id r 0x0110 this ?ld identi?s the block as type spdif input. spdif input id = 0x0110. 15:12 maj_rev r 0 major revision id 11:8 min_rev r 0x1 minor revision id 7:0 aperture r 0 aperture size the module_id register allows software identi?ation of the spdif input module. the values found in the module_id register will change with each version of the spdif input module. table 6: spdif input registers ?ontinued bit symbol acces s value description
1. introduction memory-based scaling is done independent of any video clocks by reading the video data from memory and writing the scaled pictures back to the memory. a single scaler can therefore be used to scale more than one video stream. the memory-based scaler can perform the following operations: vertical and horizontal scaling linear and non-linear aspect-ratio conversion de-interlacing simple median majority-selection (median ?tering with previous ?ld, spatial temporal average of 2 ?lds, same position from next or previous ?ld depending on whether three or two ?ld majority selection) [note: majority selection is done on luma only] field insertion 1 and line doubling ( i.e. , repeating the same line twice). ... not straightforward but doable with programming tricks edge-dependent de-interlacing (eddi) --- a post-processing step done only on luma anti-?cker ?tering conversions between 4:2:0, 4:2:2 and 4:4:4 indexed to true color conversion color expansion/compression (different quantizations for color components, e.g., rgb565 -> rgb32) deplanarization/planarization variable color space conversion with programmable matrix coef?ients (mutually exclusive with horizontal scaling) color-key and alpha processing conversion between color-key and alpha alpha scaling chapter 19: memory based scaler pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet 1. the current mbs implementation can not perform film-mode detection.
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-2 measurements histogram measurement noise estimation blackbar detection blacklevel measurement uv bandwidth measurement task-list based programming most of the above functions can be performed during a single pass, though the ?ter quality (length) may vary depending on the performed operations. special mode and features: color key to alpha and alpha to color key conversion (color re-keying) non-linear phase interpolation (phase lut) 2. functional description 2.1 mbs block level diagram figure 1: mbs block diagram coefficients pixel fetch unit pixel store unit pio & task data flow switch 12 line delay units deinterlace deinterlace 6 taps fir 6 taps fir 6 taps fir 24 pixel delay units coefficients %2 x2 alpha 6 taps fir coefficients 6 taps fir
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-3 2.2 data flow this section gives an idea of the processing functions in the mbs. figure 2 shows the top-level structure of mbs. there are two independent processing pipelines ?vertical processing pipeline and horizontal processing pipeline ?that, for most applications, can be used in any order; for 3-?ld majority selection, however, vertical processing has to be done ?st. 2.2.1 horizontal processing pipeline figure 3 elaborates on the horizontal processing pipeline (hpp). hpp is responsible for chroma up-sampling, horizontal scaling, color-space conversion, and chroma down-sampling. note that only one of either horizontal scaling or color-space conversion can be done at any one time., i.e., these operations are mutually exclusive. the scaler coef?ients are the same for both chroma and luma. figure 2: mbs top level pixel fetch unit vertical processing horizontal processing pixel store unit dma1 dma2 dma3 dma4 dma5 dma6 8/8/8/8 8/8/8/8 8/8/8/8 8/8/8/8 8/8/8/8 8/8/8/8 data path control measurement block figure 3: mbs horizontal processing pipeline 8/8/8/8 iff (4:2:2 ->4:4:4) 8/8/8/8 horizontal scaling pipeline or color space conversion 8/8/8/8 dff (4:4:4 ->4:2:2) 8/8/8/8
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-4 2.2.2 vertical processing pipeline figure 4 shows the vertical processing pipeline (vpp). vpp comprises de- interlacing, eddi-based post-processing, and vertical scaling (that also allows 4:2:0 <-> 4:2:2 sampling conversions for chroma). de-interlacing for luma samples uses majority-select or median ?tering; de-interlacing for chroma always uses median ?tering. for vertical scaling, there are 2 separate coef?ient tables: one for luma and the other for chroma, thereby allowing the use of different ?ter coef?ients for chroma and luma. figure 4: mbs vertical processing pipeline 8/8/8/8 deinterlacing eddi mux 8/8/8/8 vertical scaling pipeline (4:2:0 <->4:2:2) 8/8/8/8 8/8/8/ 8/8 8/8/8/8 8/8 ... 7 lines in total ... 12 lines in total
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-5 2.3 data processing in mbs t ab le 1 , t ab le 2 , and t ab le 3 tabulate the various processing modes and orders in the mbs. table 1: pipeline processing (horizontal first mode) input iff 1 horizontal dff 2 vertical output - 4:2:0 input (semi) planar - 4:2:2 input up-sample to 4:4:4 - color space conversion (full matrix plus offset) or - scaling only (6 tap direct or transposed polyphase) down- sample to 4:2:x -de-interlacing 3 and/or - scaling (6 tap direct polyphase) - 4:2:0 output (semi) planar - 4:2:2 output (packed, semi- planar, planar) - 4:4:4 input (8-32 bpp) - lut mode (8/4/2/1 bpp) 4 bypass bypass - scaling only (4 tap direct polyphase) and/or - anti flicker (static 4 tap ?ter) - 4:4:4 output (16-32 bpp) - 4:4:4:4 output (16-32 bpp) - 4:4:4:4 input (16-32 bpp) - lut mode (8/4/2/1 bpp) 5 bypass - scaling only (3 tap direct polyphase) bypass - scaling only (3 tap direct polyphase) and/or - anti flicker (static 3 tap ?ter) 1 interpolation fir filter 2 decimation fir filter 3 vtm (luma and chroma) or 2 ?ld msa (luma) with or without eddi (see t ab le 3 for de-interlacing). 4 alpha component from lut is not used. 5 alpha component from lut is used. table 2: pipeline processing (vertical first mode) input vertical iff horizontal dff output - 4:2:0 input - 4:2:2 input - de-interlacing (see t ab le 3 ) and/or - scaling (6 tap direct polyphase) up- sample to 4:4:4 - color space conversion (full matrix plus offset) or - scaling (6 tap direct or transposed polyphase) down- sample to 4:2:x - 4:2:0 output (2-3 planes) - 4:2:2 output (packed, semi- planar, planar) - 4:4:4 input (8-32 bpp) - lut mode (8/4/2/1 bpp) - scaling (4 tap direct polyphase) and/or - anti flicker (static 4 tap ?ter) bypass bypass - 4:4:4 output (16-32 bpp) - 4:4:4:4 output (16-32 bpp) - 4:4:4:4 input (16-32 bpp) - lut mode (8/4/2/1 bpp) - scaling (3 tap direct polyphase) and/or - anti flicker (static 3 tap ?ter) bypass - scaling (3 tap direct polyphase) bypass table 3: de-interlacing mode maximum filter lengths input format eddi msa 2 field (y:uv taps) msa 3 field (y:uv taps) median (y:uv taps) 4:2:0 or 4:2:2 planar yes 6:6 not supported 6:6 4:2:0 or 4:2:2 semi-planar yes 6:6 6:6 1 6:6 4:2:2 single plane no not supported not supported 6:6 1 only supported in vertical-first mode
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-6 2.4 general operations this section provides the details on how the mbs functions. a description of each functional group is provided. 2.4.1 task control since the mbs is capable of processing several video streams in sequence, a pipelining mechanism is implemented for scaling a sequence of tasks. a task is described by a data structure stored in memory. writing the base address of this task into the task fifo schedules the task to be executed after the completion (processing) of the previously-scheduled tasks. in addition to the task list in the fifo, each task structure in memory can consist of a linked list of sub tasks that will be executed in sequence ( e.g. , hd scaling task via partitioning). the software scheduling algorithm is responsible for preventing the task fifo from over?wing. an interrupt can be generated, once the last task in the fifo gets executed, in order to request new tasks from the scheduler. other interrupt events also exist and they aid in the task of keeping the task fifo ?led and avoiding over?w in the four available fifo slots. t ab le 4 shows the opcodes allowed in a descriptor list. the data structure consists of 32 bit words; therefore, endian mode rules do apply. the command type is de?ed in the lower two bits of the 32-bit word. the remaining bits are decoded depending on the command type. figure 5: task fifo and linked list base 1 base 2 empty empty sub-task base descriptor #1 start ... descriptor #2 start ... descriptor #2 end sub-task start ... descriptor #1 end memory fifo in fifo out four entries
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-7 2.4.2 video source controls source video data for the mbs can be fetched via three dedicated dma engines. it can be fetched from memory in several packed or planar formats. the source window is de?ed by one set of width and height values which are automatically translated into the corresponding number of 64-bit words to be fetched per line for each plane. video lines can be fetched in a reverse order as well, thereby allowing horizontal ?pping of images for applications like video conferencing. to allow fetching of interlaced video lines from different locations in memory, each plane can be assigned a second set of base address registers. pitches are de?ed separately only for luma and chroma planes. the lower three bits of the ?st three base address registers are used as an intra-long-word offset for the leftmost pixel components of each line. the offset has to be a multiple of the number of bytes per component. fixed input formats the ?ed input formats, as shown in t ab le 5 , consist of indexed, packed and planar modes. table 4: task descriptor opcode table command bits function description jump link to address 25:3 address de?es location where processing of commands continues. 1:0 opcode = 00 (binary) exec/stop end of task list 2 stop ?g if this ?g is set, processing of the mbs task is stopped. 1:0 opcode = 01 (binary) queue start processing and queue next task 25:3 address task at this location is started after processing of current task ?ished. 1:0 opcode = 10 (binary) load load register 31:24 count de?e number of registers to be loaded minus one. 19:16 mask write mask, if bit is zero according byte is written, if bit is set byte is not written. 11:2 index load registers starting at offset. 1:0 opcode = 11 (binary)
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-8 for indexed formats, sizes of 1, 2, 4, or 8 bits per pixel can be selected. a 32-bit color look up table is used to expand indexed modes into true color, including alpha values. prede?ed packed modes are available for yuy2 and uyvy formats. other packed modes can be selected by using one of the three variable input formats described below. planar formats can be used to fetch pixel components from different locations in memory. in semi-planar modes, a video ?ld is de?ed by one plane for y samples and one shared plane for u/v. in full planar formats, each component is fetched from a separate plane. when processing a 4:2:2 or 4:2:0 input stream, the ?st sample fetched from memory has to be a y/u pair! variable input formats in addition to the prede?ed ?ed input pixel formats above, the mbs also includes three variable input format modes for packed 4:4:4 and 4:2:2 pixel extraction. in these modes, the pixel components can be extracted from programmable locations within 32- or 16-bit units. 2.4.3 horizontal video filters interpolation filter all horizontal video processing is based on equidistant sampled components. all 4:2:2 video streams, therefore, have to be up-sampled before being scaled horizontally. the interpolation fir ?ter used can interpolate interspersed or co-sited chroma samples. mirroring of samples at the ?ld boundaries compensate for run in and run out conditions of the ?ter. table 5: input pixel formats format 3 1 3 0 2 9 2 8 2 7 2 6 2 5 2 4 2 3 2 2 2 1 2 0 1 9 1 8 1 7 1 6 1 5 1 4 1 3 1 2 1 1 1 0 9 8 7 6 5 4 3 2 1 0 1 bit indexed i 2 bit indexed 2 4 bit indexed 4 bit 8 bit indexed 8 bit index yuv 4:4:4, planar yuv 4:2:x, planar rgb 4:4:4, planar plane #1 plane #2 plane #3 y8 or r8 u8 or g8 v8 or b8 yuv 4:2:x, semi planar plane #1 plane #2 y8 v8 u8 packed yuy2 4:2:2 u8 or v8 y8 packed uyvy 4:2:2 y8 u8 or v8 packed variable 16 bit variable yuv or rgb 4:4:4 packed variable 32 bit variable yuv 4:4:4 , 4:2:2 or rgb 4:4:4
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-9 decimation filter after horizontal processing, chrominance may be down sampled to reduce memory bandwidth or allow for higher quality vertical processing that is not available otherwise. mirroring of samples at the ?ld boundaries compensate for run in and run out conditions of the ?ter. normal polyphase filter mode the normal polyphase ?ter can be used to zoom out or downscale a video image. depending on the number of components, the ?ter uses 6 taps (three-component mode) or 3 taps (four-component mode). for the normal polyphase ?ter, run-in and run-out behavior are compensated by appropriate mirroring of samples at the ?ld boundaries. in order to align the ?st output pixel with the geometric location of the ?st input pixel, the start phase has to be chosen as: (17) transposed polyphase filter mode the transposed polyphase ?ter can only be used to downscale. by reversing the ?w through the normal polyphase ?ter, the transposed ?ter takes the output pixels as reference and accumulates input pixels. the advantage of the transposed polyphase ?ter is the longer effective ?ter length which allows for ?tering out high frequencies that interfere with downscaling. a drawback of this approach is that the ?ter coef?ients have to get optimized for the scaling ratio in order to avoid visible dc ripples. compensation for run-in and run-out behavior of the ?ter is not available. use of the transposed ?ter is limited to three components only. the scaling ratio for the transposed polyphase hsp_zoom_0 = 0x1 0000h * zoom_x , with zoom_x = pixel_out / pixel_in linear phase interpolation mode (lpi) in the linear phase interpolation mode, samples between two pixels are interpolated by using the linear equation px = (1-phase) * x left + phase * x right . linear phase interpolation creates adequate results especially when used with computer generated graphics which, unlike motion video, is usually not bandwidth limited. the lpi mode is enabled by setting hsp_phase_mode = 7. horizontal processing mode has to be set to normal polyphase (hsp_mode = 2) and four-component mode has to be enabled (hsp_fir_comp = 1) color space matrix mode in addition to the normal and transposed polyphase ?tering (scaling), the fir ?ter structure can instead be programed to perform color-space-conversion functions. a dedicated set of registers holds the coef?ients for the color space matrix. dto_offset 0x200 filter_length ? =
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-10 2.4.4 vertical video filters the polyphase ?ter used for vertical processing can only be operated in the normal polyphase mode.this ?ter can be used as a two-component 6-tap ?ter, a three- component 4-tap ?ter or a four-component 3-tap ?ter (optionally, linear phase interpolation). in the two-component mode, each ?ter unit can be run independently, to allow 4:2:0 to 4:2:2 conversion or vice versa. 2.4.5 de-interlacing in mbs the current de-interlacing algorithms, implemented inside the mbs, are as follows: simple median filtering (vertical temporal median -- vtm) majority selection algorithm (msa) field insertion and line doubling mbs supports both ?ld insertion and line doubling based simple de-interlacing in the pixel-fetch unit. if de-interlacing is enabled, the previous and current ?lds have to be fed into the scaler as one interleaved frame. for the msa, the ?st line has to originate in the previous ?ld, while in vtm, the ?st line has to be fetched from the current ?ld. base address mode = 1 can be selected to assist in weaving the two ?lds together into one frame. edge dependent de-interlacing (eddi) the purpose of eddi is to improve the appearance of long diagonal edges, without degrading other parts of the image. eddi is used as a post-processing unit for the de- interlacer. 2.4.6 color-key processing color-key processing, to convert alpha values into color key values and/or vice versa, are only available for the 4:4:4 video formats. color key to alpha conversion to avoid color key values getting altered during video processing, color-key matching samples can be tagged as transparent by generating an alpha value of zero at the input of the mbs. non- keyed samples get assigned a programmable alpha value. after video processing is over, the alpha value can be stored in memory together with the other components or can be used to re-key the keying color back into the video stream (see alpha to color k e y con v er t below ) color key replace scaling of video streams containing color keys can lead to artifacts at the corners between keyed and non- keyed samples, due to the ?mearing effect of the low pass ?ter. the effect is heightened by the highly saturated colors normally used for keying. to avoid these artifacts, color keyed samples are replaced with either gray, black, or the previous sample (gray if at the start of the line),. alpha to color key convert
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-11 if the alpha value, after horizontal and vertical processing, is below a ?ed threshold (0x80), the sample is replaced by the color key. fixed alpha insert the alpha value de?ed in the color key register is inserted, as the fourth component after horizontal and vertical processing, in the psu unit (if ckey_k2a=1). 2.4.7 alpha processing alpha processing is only available when the horizontal and vertical ?ter blocks are either bypassed or operated in the four-component mode. if the horizontal ?ter is used for color space conversion, the alpha information is kept time-aligned with the other three components. 2.4.8 video data output after processing the video stream, the mbs can split the video data into one or more (up to three) different streams. for each stream, there is a memory base address. there are two line-pitch registers further de?ing the dma streams. the number of streams (planes) is de?ed by the output-format register. depending on its value, the video components get packed into 64-bit words. these words then get buffered and transferred to the external memory in more effective clusters. a list of the supported output video formats is shown in t ab le 6 . packing of a pixel into 64-bit units is always done from right to left, while bytes within one pixel unit are ordered according to the endian settings (according to the global endian setting, the endian bit in the output format register can invert the setting). remark: t ab le 6 shows location of the first ?ixel unit within a 64 bit word in the little endian mode. the selected endian mode will affect the position of the components within multi-byte pixel units! table 6: output pixel formats format 3 1 3 0 2 9 2 8 2 7 2 6 2 5 2 4 2 3 2 2 2 1 2 0 1 9 1 8 1 7 1 6 1 5 1 4 1 3 1 2 1 1 1 0 9 8 7 6 5 4 3 2 1 0 planar yuv or rgb (4:4:4, 4:2:2 or 4:2:0) plane #1 plane #2 plane #3 y8 or r8 u8 or g8 v8 or b8 semi planar yuv (4:2:2 or 4:2:0) plane #1 plane #2 y8 or r8 v8 u8 packed 4/4/4 rgba alpha r4 g4 b4 packed 4/5/3 rgba alpha r4 g5 b3 packed 5/6/5 rgb r5 g6 b5 packed yuy2 4:2:2 u8 or v8 y8 packed uyvy 4:2:2 y8 u8 or v8 packed 888 rgb(a) (alpha) r8 or y8 g8 or u8 b8 or v8 packed 4:4:4 vyu(a) (alpha) v8 y8 u8
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-12 2.4.9 address generation each of the three video planes is assigned a set of two base address registers and two line address pointers. depending on the base address mode, video data corresponding to each plane is written using one pointer, or using both pointers alternating on each line. at the end of the line, the pitch value is added to the active line address pointer. the pitch de?es the difference in the address of two vertically adjacent pixels. the pitch values are de?ed separately for chroma and luma components only. the lower three bits of the ?st three base address registers are used as an intra-long-word offset for the leftmost pixel components of each line. the offset has to be a multiple of the number of bytes per component. 2.4.10 interrupt generation the following interrupt events are de?ed: task_error current processing task leads to a pipeline error, mbs has to be reset to resume with new scaling task(s). task_end current task processing is done, but some data might still remain in the output fifo - this interrupt denotes the point when the mbs is ready to start the processing of a new task. task_overflow task ?o over?w - task request written into task- ?o-register got ignored. task_idle task ?ished and the task ?o is empty. task_empty task ?o runs empty - generation of this interrupt requires that there was a pending task in the task ?o. this interrupt will not be generated if tasks are only submitted in the mbs idle state. task_done current task ?ished and all writes complete - on reception of this interrupt, all data will be accessible in the main memory.
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-13 2.4.11 measurement functions all measurements in the mbs are based on analyzing a video stream, within a programmable window, using speci? algorithms. the measurement results are stored in registers once per ?ld/frame. a special interrupt is generated to indicate that the measurement is done. based on the measurement results, software sets the control parameters for the picture processing units. as shown in figure 6 , the mbs measurement block comprises: measurement block interface converts the inputs format (y, u/v 8bits) into the format needed by the measurement units (y, u/v 9bits). histogram measurement analyses the y component of the input data stream. used for dynamic contrast improvement (i.e., histogram modi?ation in qvcp). noise estimator analyses the y component. controls the setting of lshr pool ressource in qvcp. black bar detector analyses the y component. results are used to expand the picture to the display size in case of black bars at the top and/or bottom of the picture. black level measurement analyses the y component. used for black stretch. figure 6: measurement in the mbs measurement interface noise estimator histogram measurement black bar detector black level measurement uv bandwidth measurement 8/8 registers
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-14 uv bandwidth measurement analyses the uv component. controls the dcti setting in qvcp. remark: mbs and qtnr both use the same measurement functions/block. 3. register descriptions 3.1 register summary table 7: register summary offset name description 0x10 c000 mbs_mode mbs operation mode 0x10 c040 task_queue task queue fifo 0x10 c044 task_status 1 task queue status 0x10 c048 task_status 2 shows last command executed 0x10 c100 pfu_format input format and mode 0x10 c104 pfu_window source window size 0x10 c108 pfu_varform variable source format 0x10 c140 pfu_base1 source base address dma #1 0x10 c144 pfu_pitch1 source line pitch component 1 0x10 c148 pfu_base2 source base address dma #2 0x10 c14c pfu_pitch2 source line pitch component 2 and 3 0x10 c150 pfu_base3 source base address dma #3 0x10 c154 pfu_base4 source base address dma #4 0x10 c158 pfu_base5 source base address dma #5 0x10 c15c pfu_base6 source base address dma #6 0x10 c200 hsp_zoom_0 initial zoom for 1st pixel in line (unsigned) 0x10 c204 hsp_phase horizontal phase control 0x10 c208 hsp_dzoom_0 initial zoom delta for 1 pixel in line (signed) 0x10 c20c hsp_ddzoom zoom delta change (signed) 0x10 c220 csm_coeff0 color space matrix coef?ients c 00 - c 02 0x10 c224 csm_coeff1 color space matrix coef?ients c 10 - c 12 0x10 c228 csm_coeff2 color space matrix coef?ients c 20 - c 22 0x10 c22c csm_offs1 color space matrix offset coef?ients d 0 -d 2 0x10 c230 csm_offs2 color space matrix rounding coef?ients e 0 -e 2 0x10 c240 vsp_zoom_0 initial zoom for 1st pixel in line (unsigned) 0x10 c244 vsp_phase vertical phase control 0x10 c248 vsp_dzoom_0 initial zoom delta for 1 pixel in line (signed) 0x10 c24c vsp_ddzoom zoom delta change (signed) 0x10 c260 eddi_ctrl1 eddi control register 1
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-15 0x10 c264 eddi_ctrl2 eddi control register 2 0x10 c280 ckey_mask color key and alpha control 0x10 c284 ckey_value color key and alpha components 0x10 c300 psu_format output format and mode 0x10 c304 psu_window target window size 0x10 c340 psu_base1 target base address dma #1 0x10 c344 psu_pitch1 target line pitch component 1 0x10 c348 psu_base2 target base address dma #2 0x10 c34c psu_pitch23 target line pitch component 2 and 3 0x10 c350 psu_base3 target base address dma #3 0x10 c354 psu_base4 target base address dma #4 0x10 c358 psu_base5 target base address dma #5 0x10 c35c psu_base6 target base address dma #6 0x10 c400 c7fc color_table color look-up table 0x10 c800 c9fc coeff_table1 coef?ient table for horizontal ?ter (0-5) 0x10 ca00 cdfc coeff_table2 coef?ient table for vertical luma ?ter (0-5) 0x10 cc00 cdfc coeff_table3 coef?ient table for vertical chroma ?ter (0-5) 0x10 ce00 format_ctrl formatter control 0x10 ce0c flag_ctrl measurement ?ish mask 0x10 ce10 histo_ctrl histogram control 0x10 ce18 histo_win_start histogram window start 0x10 ce1c histo_win_end histogram window end 0x10 ce20 nest_ctrl1 noise estimation control 1 0x10 ce24 nest_ctrl2 noise estimation control 2 0x10 ce28 nest_hwin noise estimation window start 0x10 ce2c nest_vwin noise estimation window end 0x10 ce30 bbd_ctrl black bar detection control 0x10 ce38 bbd_win_start black bar detection window start 0x10 ce3c bbd_win_end black bar detection window end 0x10 ce40 bld_ctrl black level detection control 0x10 ce48 bld_win_start black level window start 0x10 ce4c bld_win_end black level window end 0x10 ce50 bwd_ctr /data_1 uv bandwidth detection control 0x10 ce58 bwd_win_start uv bandwidth window start 0x10 ce5c bwd_win_end uv bandwidth window end table 7: register summary ?ontinued offset name description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-16 3.2 register table 0x10 ce8f histo_data_1 histogram status 0x10 ce90 histo_data_2 histogram data output 0x10 ce94 histo_data_3 histogram data output 0x10 ce98 histo_data_4 histogram data output 0x10 ce9c histo_data_5 histogram data output 0x10 cea0 histo_data_6 histogram data output 0x10 cea4 histo_data_7 histogram data output 0x10 cea8 histo_data_8 histogram data output 0x10 ceac histo_data_9 histogram data output 0x10 ceb0 nest_data_1 noise estimation status 1 0x10 ceb4 nest_data_2 noise estimation status 2 0x10 ceb8 bbd_data_1 black bar detection status 1 0x10 cebc bbd_data_2 black bar detection status 2 0x10 cec0 bld_data black level detection status 0x10 cec4 bwd_data_1 uv bandwidth detection status 1 0x10 cec8 bwd_data_2 uv bandwidth detection status 2 0x10 cfe0 int_status interrupt status register 0x10 cfe4 int_enable interrupt enable register 0x10 cfe8 int_clear interrupt clear register 0x10 cfec int_set interrupt set register 0x10 cffc module_id module identi?ation and revision information table 7: register summary ?ontinued offset name description table 8: memory based scaler (mbs) registers bit symbol acces s value description operating mode control registers offset 0x10 c000 mbs mode control 31:30 dpm_seq r/w 0 data path sequence 0x: bypass all ?ter stages (format conversion only) 10: hsp -> vsp 11: vsp -> hsp 29 alt_msa3 r/w 0 1: chose alternate msa3 mode 28 previous_first_c r/w 0 1: previous ?ld ?st (chroma) 27 previous_first_l r/w 0 1: previous ?ld ?st (luma) 26 enable_eddi r/w 0 1: enable eddi
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-17 25:24 vsp_de-interlace r/w 0 de-interlacing mode 00: no de-interlacing 01: vertical temporal median 10: majority selection algorithm (2 ?ld) 11: majority selection algorithm (3 ?ld) 23:22 reserved 21:20 coeff_lut_mode r/w 0 coef?ient look-up table access mode 00: each table gets written separately 01: writes to coeff table 2 are copied into table 3 10: writes to coeff table 1 are copied into table 2 11: writes to coeff table 1 are copied into table 2 and 3 19 disable_irq r/w 0 1: disables the mbs interrupts- task done and task idle. used for concatenated tasks. 18 no_auto_skip r/w 0 disable auto skip when set to zero (default) the mbs will automatically skip all remaining operations within a task once the task_done interrupt was generated. if enable the mbs will continue until all pipeline stages are idle. 17 skip_task w 0 skip current task writing a one into this bit will reset the current task and continue with previously scheduled tasks 16 soft_reset w 0 soft reset writing a one into this bit will reset the block and all outstanding scaling tasks 15 reserved 14 iff_clamp r/w 0 clamp mode for iff (affects u/v only) 0: clamp to 0-255 1: clamp to 16 - 240 (ccir range) 13:12 iff_mode r/w 0 interpolation mode 00: bypass 01: reserved 10: co-sited 11: interspersed 11 reserved 10 dff_clamp r/w 0 clamp mode for dff (affects u/v only) 0: clamp to 0-255 1: clamp to 16 - 240 (ccir range) 9: 8 dff_mode r/w 0 decimation mode 00: bypass 01: co-sited (sub sample) 10: co-sited (low pass) 11: interspersed 7 vsp_clamp r/w 0 clamp mode for vsp 0: clamp to 0-255 1: clamp to ccir range de?ed by vsp_rgb (bit 6) table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-18 6 vsp_rgb r/w 0 color space mode, de?es ccir clamping range for vsp 0: processing in yuv color space (ccir range: 16 - 235(y), 16 - 240(u/v)) 1: processing in rgb color space (ccir range: 16 - 235) 5:4 vsp_mode r/w 0 vertical processing mode 00: bypass mode 01: reserved 10: normal polyphase mode 11: reserved 3 hsp_clamp r/w 0 clamp mode for hsp 0: clamp to 0-255 1: clamp to ccir range de?ed by hsp_rgb (bit 2) 2 hsp_rgb r/w 0 color space mode, de?es ccir clamping range for hsp 0: processing in yuv color space (ccir range: 16 - 235(y), 16 - 240(u/v)) 1: processing in rgb color space (ccir range: 16 - 235) 1:0 hsp_mode 0 horizontal processing mode 00: bypass mode 01: color space matrix mode 10: normal polyphase mode 11: transposed polyphase mode video informations registers offset 0x10 c040 task fifo 31:3 task_base w scale task fifo must be aligned to 8 byte boundary 2 reserved 0 1:0 task_cmd w command mode 00: process task descriptor at given base 01: start scaling with current register settings 1x: reserved offset 0x10 c044 task status 1 31:4 reserved 0 3:0 task_pending r number of pending scaling tasks (including current) offset 0x10 c048 task status 2 31:0 last_command r last command executed input format control registers offset 0x10 c100 input format table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-19 31:30 pfu_bamode r/w 0 base address mode 00 = single set (e.g. progressive video source) base 1-3 according to number of planes (plane 1-3) 01 = alternate sets each line (e.g. interlaced video source) base 1-3, ?st line in, etc. (plane 1-3) base 4-6, second line in, etc. (plane 1-3) 1x = reserved 29:16 reserved 15 pfu_hflip r/w mirror input mode 0: normal 1: mirrored input 14 reserved r/w 13 pfu_endian r/w input format endian mode 0: same as system endian mode 1: opposite of system endian mode 12:8 reserved 7:0 pfu_ipfmt r/w 0 input formats 00 (hex) = yuv 4:2:0, semi-planar 03 (hex) = yuv 4:2:0, planar 08 (hex) = yuv 4:2:2, semi-planar 0b (hex) = yuv 4:2:2, planar 0f (hex) = rgb or yuv 4:4:4, planar 24 (hex) = 1-bit indexed 45 (hex) = 2-bit indexed 66 (hex) = 4-bit indexed 87 (hex) = 8-bit indexed a0 (hex) = packed yuy2 4:2:2 a1 (hex) = packed uyvy 4:2:2 ac (hex) = 16-bit variable contents 4:4:4 e8 (hex) = 32-bit variable contents 4:2:2 ec (hex) = 32-bit variable contents 4:4:4 offset 0x10 c104 source window size 31:27 reserved 26:16 pfu_lsize r/w 0 line size de?es size of input window 1 = one pixel remark: internal buffer lines are only 1024 pixels. horizontal and vertical scaling need to be ordered such that the intermediate result fits into 1024 pixels buffer lines. 15:11 reserved 10:0 pfu_lcount r/w 0 line count de?es size of input window 1 = one line offset 0x10 c108 variable format register 31:29 pfu_size_c4 [2:0] r/w 0 size component #4 (alpha or v) number of bits minus 1 (e.g. 7 = 8 bits per component) table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-20 28:24 pfu_offs_c4 [4:0] r/w 0 offset component #4 (alpha or v) index of msb position within 32 bit word (0-31) 23:21 pfu_size_c3 [2:0] r/w 0 size component #3 (v or b or y2) number of bits minus 1 (e.g. 7 = 8 bits per component) 20:16 pfu_offs_c3 [4:0] r/w 0 offset component #3 (v or b or y2) index of msb position within 32 bit word (0-31) 15:13 pfu_size_c2[2:0] r/w 0 size component #2 (u or g) number of bits minus 1 (e.g. 7 = 8 bits per component) 12:8 pfu_offs_c2[4:0] r/w 0 offset component #2 (u or g) index of msb position within 32 bit word (0-31) 7:5 pfu_size_c1[2:0] r/w 0 size component #1 (y or r) number of bits minus 1 (e.g. 7 = 8 bits per component) 4:0 pfu_offs_c1[4:0] r/w 0 offset component #1 (y or r) index of msb position within 32 bit word (0-31) video input address generation control registers offset 0x10 c140 source base address #1 31:28 unused - 27: 3 pfu_base1 r/w base address dma #1 used depending on pfu_bamode setting 2:0 pfu_offset1 r/w base address byte offset dma #1 bits de?e pixel offset within multi pixel 64 bit words (e.g. a 16bit pixel can be placed on any 16 bit boundary) offset 0x10 c144 source line pitch #1 31:15 unused - 14: 3 pfu_pitch1 r/w 0 line pitch dma #1, signed value (twos complement) used for all packed formats and for plane 1. 2:0 unused - offset 0x10 c148 source base address #2 31:28 unused - 27: 3 pfu_base2 r/w base address dma #2 used depending on pfu_bamode setting. 2:0 pfu_offset2 r/w base address byte offset dma #2 bits de?e pixel offset within multi pixel 64-bit words (e.g., a 16-bit pixel can be placed on any 16-bit boundary). offset 0x10 c14c source line pitch #2 31:15 unused - 14: 3 pfu_pitch2 r/w line pitch dma #2, signed value (twos complement) used for planes 2 and 3. 2:0 unused - offset 0x10 c150 source base address #3 31:28 unused - 27: 3 pfu_base3 r/w base address dma #3 used depending on pfu_bamode setting. table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-21 2:0 pfu_offset3 r/w base address byte offset dma #3 bits de?e pixel offset within multi pixel 64-bit words (e.g., a 16-bit pixel can be placed on any 16-bit boundary). offset 0x10 c154 source base address #4 31:28 unused - 27: 3 pfu_base4 r/w base address dma #4 used depending on pfu_bamode setting. 2:0 unused - offset 0x10 c158 source base address #5 31:28 unused - 27: 3 pfu_base5 r/w base address dma #5 used depending on pfu_bamode setting. 2:0 unused - offset 0x10 c15c source base address #6 31:28 unused - 27: 3 pfu_base6 r/w base address dma #6 used depending on pfu_bamode setting. 2:0 unused - horizontal video processing control registers offset 0x10 c200 initial zoom 31:29 hsp_phase_mode[2: 0] r/w 0 phase mode 0: 64 phases 1: 32 phases 2: 16 phases 3: 8 phases 4: 4 phases 5: 2 phases 6: ?ed phase 7: linear phase interpolation (only valid for 4 component mode) 28 hsp_no_crop r/w 0 disable line length cropping 0: cropping enabled (default) 1: cropping disabled, used for striped scaling tasks 27 hsp_uv_seq r/w 0 chroma sample re-sequence 0: normal sequence (default) 1: skip ?st chroma sample (used for striped scaling tasks in 4:2:x transposed mode if stripe would start on an odd pixel location.) 26 hsp_fir_comp[1:0] r/w horizontal ?ter components 0: three components, 6 tap fir each 1: four components, 3 tap fir each in color space matrix mode this value has to remain zero. 25:20 reserved table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-22 19: 0 hsp_zoom_0[19:0] r/w 0 initial zoom for 1st pixel in line (unsigned, lsb = 2 -16 ) 2 0000 (hex): downscale 50% 1 0000 (hex): no scaling = 100% 0 8000 (hex): zoom 2 x (transposed: downscale 50%) offset 0x10 c204 phase control 31 reserved - 30:28 hsp_qshift[2:0] r/w 0 quantization shift control used to change quantization before being multiplied with hsp_multiply. 100 (bin): divide by 16 101 (bin): divide by 8 110 (bin): divide by 4 111 (bin): divide by 2 000 (bin): multiply by 1 001 (bin): multiply by 2 010 (bin): multiply by 4 011 (bin): multiply by 8 warning: a value range over?w caused by an improper quantization shift can not be compensated later by multiplying with a hsp_multiply value below 0.5! 27:26 reserved - 25 hsp_qsign r/w 0 quantization sign bit 24:16 hsp_qmultiply[8:0] r/w 0 quantization multiply control used to compensate for different weight sums in transposed polyphase or color space matrix mode, remaining bits are fractions (largest number is 511/512) value range: . instead of using values in the range of the quantization shift hsp_qshift should be modi?d to gain more precision in the truncated result. 15:13 reserved - 12: 0 hsp_offset_0 r/w 0 initial start offset for dto offset 0x10 c208 initial zoom delta 31:26 reserved 25: 0 hsp_dzoom_0[25:0] r/w 0 initial zoom delta for 1 pixel in line (signed, lsb = 2 -27 ) used for non constant scaling ratios. offset 0x10 c20c zoom delta change 31:29 reserved - 28: 0 hsp_ddzoom[28:0] r/w 0 zoom delta change (signed, lsb = 2 -40 ) used for non constant scaling ratios color space matrix registers offset 0x10 c220 color space matrix coef?ients c 00 - c 02 31:30 unused - 29:20 csm_c02[9:0] r/w 0 coef?ient c02, twos complement 19:10 csm_c01[9:0] r/w 0 coef?ient c01, twos complement 9:0 csm_c00[9:0] r/w 0 coef?ient c00, twos complement table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description 0 m 1.0 < m 0.5 <
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-23 offset 0x10 c224 color space matrix coef?ients c 10 - c 12 31:30 unused - 29:20 csm_c12[9:0] r/w 0 coef?ient c12, twos complement 19:10 csm_c11[9:0] r/w 0 coef?ient c11, twos complement 9:0 csm_c10[9:0] r/w 0 coef?ient c10, twos complement offset 0x10 c228 color space matrix coef?ients c 20 - c 22 31:30 unused - 29:20 csm_c22[9:0] r/w 0 coef?ient c22, twos complement 19:10 csm_c21[9:0] r/w 0 coef?ient c21, twos complement 9:0 csm_c20[9:0] r/w 0 coef?ient c20, twos complement offset 0x10 c22c color space matrix offset coef?ients d 0 - d 2 31:29 unused - 28 csm_d2_twos r/w 0 offset coef?ient d 2 type 0 = unsigned 1 = signed 27:20 csm_d2[7:0] r/w 0 offset coef?ient d 2 19 unused - 18 csm_d1_twos r/w 0 offset coef?ient d 1 type 0 = unsigned 1 = signed 17:10 csm_d1[7:0] r/w 0 offset coef?ient d 1 9 unused - 8 csm_d0_twos r/w 0 offset coef?ient d 0 type 0 = unsigned 1 = signed 7:0 csm_d0[7:0] r/w 0 offset coef?ient d 0 offset 0x10 c230 color space matrix offset coef?ients e 0 - e 2 31:30 unused - 29:20 csm_e2[9:0] r/w 0 offset coef?ient e2, twos complement 19:10 csm_e1[9:0] r/w 0 offset coef?ient e1, twos complement 9:0 csm_e0[9:0] r/w 0 offset coef?ient e0, twos complement vertical video processing control registers offset 0x10 c240 initial zoom table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-24 31:29 vsp_phase_mode[2: 0] r/w 0 phase mode 0: 64 phases 1: 32 phases 2: 16 phases 3: 8 phases 4: 4 phases 5: 2 phases 6: ?ed phase 7: linear phase interpolation (only valid for4 component mode) 28 reserved 27:26 vsp_fir_comp[1:0] r/w vertical ?ter components 00: two components, 6 tap fir each 1 01: reserved 10: three components, 4 tap fir each 11: four components, 3 tap fir each 1 filter lengths differ when in de-interlacing mode. 25:20 reserved 19: 0 vsp_zoom_0[19:0] r/w 0 initial zoom for 1st pixel in line (unsigned, lsb = 2 -16 ) 2 0000 (hex): downscale 50% 1 0000 (hex): no scaling = 2 0 0 8000 (hex): zoom 2 x offset 0x10 c244 phase control 31 reserved - 30:28 vsp_qshift[2:0] r/w 0 quantization shift control used to change quantization before being multiplied with 0.5. 100 (bin): divide by 16 101 (bin): divide by 8 110 (bin): divide by 4 111 (bin): divide by 2 000 (bin): multiply by 1 001 (bin): multiply by 2 010 (bin): multiply by 4 011 (bin): multiply by 8 27:26 reserved - 25 vsp_qsign r/w 0 quantization sign bit 24:21 vsp_ldiff_c[3:0] r/w 0 line offset for chroma line count (signed, needed for slicing only) 20 reserved - 19:14 vsp_offset_c[12:8] - initial start offset for chroma dto (used for 4:2:0 scaling and de-interlacing only.) 13: 0 vsp_offset_0[12:0] r/w 0 initial start offset for dto offset 0x10 c248 initial zoom delta 31:26 reserved 25: 0 vsp_dzoom_0[25:0] r/w 0 initial zoom delta for 1 pixel in line (signed, lsb = 2 -27 ) used for non-constant scaling ratios. offset 0x10 c24c zoom delta change table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-25 31:29 reserved - 28: 0 vsp_ddzoom[28:0] r/w 0 zoom delta change (signed, lsb = 2 -40 ) used for non-constant scaling ratios. eddi registers offset 0x10 c260 eddi control register 1 31:28 reserved 27:24 ewm_rel r/w 0 edge width scale factor for edge matching ewm_rel/16 * max_width < min_width ewm_rel = 0 to 15 23:22 ewm_abs r/w 0 edge width difference for edge matching (max_width - min_width) < ewm_abs 21:16 min_lumdiff r/w 0 minimum luminance difference 15:9 fpx_thr r/w 0 filter threshold 8:4 max_nrp r/w 0 maximum possible width for an edge 3:1 min_nrp r/w 0 minimum required width for an edge 0 enable_eddi r/w 0 1: eddi enable note: the enable_eddi bit in mode control reg must be set to 1 for the eddi to be functional. offset 0x10 c264 eddi control register 2 31:16 reserved 15:12 rcm_rel r/w 0 rc scale factor for rc matching rcm_rel /16 * max_rc < min_rc rcm_rel = 0 to 15 11:10 rcm_abs r/w 0 rc difference for rc matching (max_rc - min_rc) < rcm_abs 9 reserved 8:4 search_limit r/w 0 search limit to ?d a matching edge search_limit/16 * edge_width search_limit = 0 to 31 3:1 reserved 0 rc_check r/w 0 1: enable rc check to calculate air color keying control registers offset 0x10 c280 color key control 31:30 ckey_k2a r/w 0 color key to alpha convert 00 = no alpha manipulation 01 = ?ed alpha at output 10 = reserved 11 = color key to alpha convert alpha value for non-key sample is taken from ckey_alpha register, alpha value for key sample is set to zero. table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-26 29:28 ckey_a2k r/w 0 alpha mode to color key convert 00 = no alpha manipulation 01 = reserved 10 = reserved 11 = alpha to color key convert samples with alpha component below 80 (hex) are replaced with values de?ed in ckey_comp 1-3. 27:26 ckey_replace r/w 0 color keying replace mode 00 = no color component manipulation 01 = replace keyed color components with black (10, 10, 10) 10 = replace keyed color components with gray (80, 80, 80) 11 = replace keyed color components with last non-key value 25:24 reserved 23: 16 ckey_mask1 r/w 0 color key mask component 1 de?es bits of color component that are compared against color key value setting to key sample. 15: 8 ckey_mask2 r/w 0 color key mask component 2 de?es bits of color component that are compared against color key value setting to key sample. 7: 0 ckey_mask3 r/w 0 color key mask component 3 de?es bits of color component that are compared against color key value setting to key sample. offset 0x10 c284 color key components 31: 24 ckey_alpha r/w 0 alpha value de?es the alpha value to be used for keyed samples. 23: 16 ckey_comp1 r/w 0 color key component 1 de?es value of color key for component 1 (red or y). 15: 8 ckey_comp2 r/w 0 color key component 2 de?es value of color key for component 2 (green or u). 7: 0 ckey_comp3 r/w 0 color key component 3 de?es value of color key for component 3 (blue or v). video output format control registers offset 0x10 c300 video output format 31:30 psu_bamode r/w 0 base address mode 00 = single set (e.g. progressive video source) base 1-3 according to number of planes (plane 1-3) 01 = alternate sets each line (e.g. anti-?cker mode) base 1-3, ?st line out, etc. (plane 1-3) base 4-6, second line out, etc. (plane 1-3) 1x = reserved 29:14 reserved 13 psu_endian r/w 0 output format endian mode 0: same as system endian mode 1: opposite of system endian mode 12 reserved table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-27 11:10 psu_dither r/w 0 output format dither mode 00: no dithering 01: error dispersion (never reset pattern) 10: error dispersion (reset pattern at startup) 11: error dispersion (reset pattern every ?ld) 9:8 psu_alpha r/w 0 output format alpha mode 00: no alpha (alpha byte not written to memory) 01: alpha byte written (see color keying control) 10: reserved 11: reserved 7:0 psu_opfmt r/w 0 output formats 00 (hex) = yuv 4:2:0, semi-planar 03 (hex) = yuv 4:2:0, planar 08 (hex) = yuv 4:2:2, semi-planar 0b (hex) = yuv 4:2:2, planar 0f (hex) = rgb or yuv 4:4:4, planar a9 (hex) = compressed 4/4/4 + (4 bit alpha) aa (hex) = compressed 4/5/3 + (4 bit alpha) ad (hex) = compressed 5/6/5 a0 (hex) = packed yuy2 4:2:2 a1 (hex) = packed uyvy 4:2:2 e2 (hex) = yuv or rgb 4:4:4 + (8 bit alpha) e3 (hex) = vyu 4:4:4 + (8 bit alpha) offset 0x10 c304 target window size 31:27 reserved 26:16 psu_lsize r/w 0 line size used for horizontal cropping after scaling. 0 = cropping disabled 1 = one pixel remark: internal buffer lines are only 1024 pixels. horizontal and vertical scaling need to be ordered such that the intermediate result fits into 1024 pixels buffer lines. 15:11 reserved 10:0 psu_lcount r/w 0 line count used for vertical cropping after scaling. 0 = cropping disabled 1 = one line video output address generation control registers offset 0x10 c340 target base address #1 31:28 unused - 27: 3 psu_base1 r/w base address dma #1 used depending on psu_bamode setting. 2:0 psu_offset1 r/w base address byte offset dma #1 bits de?e pixel offset within multi pixel 64-bit words (e.g., a 16-bit pixel can be placed on any 16-bit boundary). offset 0x10 c344 target line pitch #1 table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-28 31:15 unused - 14: 3 psu_pitch1 r/w line pitch dma #1, signed value (twos complement) used for all packed formats and for plane 1. 2:0 unused - offset 0x10 c348 target base address #2 31:28 unused - 27: 3 psu_base2 r/w base address dma #2 used depending on psu_bamode setting. 2:0 psu_offset2 r/w base address byte offset dma #2 bits de?e pixel offset within multi pixel 64-bit words (e.g., a 16-bit pixel can be placed on any 16-bit boundary). offset 0x10 c34c target line pitch #2 31:15 unused - 14: 3 psu_pitch2 r/w line pitch dma #2, signed value (twos complement) used for planes 2 and 3. 2:0 unused - offset 0x10 c350 target base address #3 31:28 unused - 27: 3 psu_base3 r/w base address dma #3 used depending on psu_bamode setting. 2:0 psu_offset3 r/w base address byte offset dma #3 bits de?e pixel offset within multi pixel 64-bit words (e.g., a 16-bit pixel can be placed on any 16-bit boundary). offset 0x10 c354 target base address #4 31:28 unused - 27: 3 psu_base4 r/w base address dma #4 used depending on psu_bamode setting. 2: 0 unused - offset 0x10 c358 target base address #5 31:28 unused - 27: 3 psu_base5 r/w base address dma #5 used depending on psu_bamode setting. 2: 0 unused - offset 0x10 c35c target base address #6 31:28 unused - 27: 3 psu_base6 r/w base address dma #6 used depending on psu_bamode setting 2: 0 unused - miscellaneous registers offset 0x10 c400?7fc color look up table 31:24 lut_alpha[x] w - alpha table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-29 23:16 lut_red[x][7:0] w - red or y 15:8 lut_green[x][7:0] w - green or u 7:0 lut_blue[x][7:0] w - blue or v offset 0x10 c800?9fc coef?ient table #1 taps 0-5 (horizontal) 63:62 unused - 61:52 tap_5[x][9:0] w - inverted coef?ient, tap #5, twos complement 51:42 tap_4[x][9:0] w - inverted coef?ient, tap #4, twos complement 41:32 tap_3[x][9:0] w - inverted coef?ient, tap #3, twos complement 31:30 unused - 29:20 tap_2[x][9:0] w - inverted coef?ient, tap #2, twos complement 19:10 tap_1[x][9:0] w - inverted coef?ient, tap #1, twos complement 9:0 tap_0[x][9:0] w - inverted coef?ient, tap #0, twos complement offset 0x10 ca00?bfccoef?ient table #2 taps 0-5 (vertical - luma) 63:62 unused - 61:52 tap_5[x][9:0] w - inverted coef?ient, tap #5, twos complement 51:42 tap_4[x][9:0] w - inverted coef?ient, tap #4, twos complement 41:32 tap_3[x][9:0] w - inverted coef?ient, tap #3, twos complement 31:30 unused - 29:20 tap_2[x][9:0] w - inverted coef?ient, tap #2, twos complement 19:10 tap_1[x][9:0] w - inverted coef?ient, tap #1, twos complement 9:0 tap_0[x][9:0] w - inverted coef?ient, tap #0, twos complement offset 0x10 cc00?dfccoef?ient table #3 taps 0-5 (vertical - chroma) 63:62 unused - 61:52 tap_5[x][9:0] w - inverted coef?ient, tap #5, twos complement 51:42 tap_4[x][9:0] w - inverted coef?ient, tap #4, twos complement 41:32 tap_3[x][9:0] w - inverted coef?ient, tap #3, twos complement 31:30 unused - 29:20 tap_2[x][9:0] w - inverted coef?ient, tap #2, twos complement 19:10 tap_1[x][9:0] w - inverted coef?ient, tap #1, twos complement 9:0 tap_0[x][9:0] w - inverted coef?ient, tap #0, twos complement measurement finish flags mask offset 0x10 ce0c flaggen control registers 31:6 reserved - - 5 eaf_bbar_enable r/w 0 ??: meas_?ish is only generated if eaf_bbar has occurred ??: meas_?ish is independent from eaf_bbar 4 eaf_blklvl_enable r/w 0 ??: meas_?ish is only generated if eaf_blklvl has occurred ??: meas_?ish is independent from eaf_blklvl 3 eaf_histo_enable r/w 0 ??: meas_?ish is only generated if eaf_histo has occurred ??: meas_?ish is independent from eaf_histo table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-30 2 eaf_noise_enable r/w 0 ??: meas_?ish is only generated if eaf_noise has occurred ??: meas_?ish is independent from eaf_noise 1 eaf_uvbw_enable r/w 0 ??: meas_?ish is only generated if eaf_uvbw has occurred ??: meas_?ish is independent from eaf_uvbw 0 eaf_?m_enable r/w 0 ??: meas_?ish is only generated if eaf_?m has occurred ??: meas_?ish is independent from eaf_?m formatter registers offset 0x10 ce00 formatter control 31:9 reserved - 8:7 line_valid [1:0] w 3 determines the lines to be measured 00 = reserved 01 = only passes even occurrences of lines for measurements 10 = only passes odd occurrences of lines for measurements 11 = passes all occurrences of lines for measurements 6 input_format_uv w 0 uv input range type selector: 0 (unsigned) = 0 (minimum) 32 (negative, 100% saturation) 256 (uncolored) 480 (positive, 100% saturation) 511 (maximum) 1 (signed) = -256 (minimum) -224 (negative, 100% saturation) 0 (uncolored) 224 (positive, 100% saturation) 255 (maximum) 5 input_format_y w 0 y input range type selector: 0 (unsigned) = 0 (minimum) 32 (black) 470 (white, 100%) 511 (maximum) 1 (signed) = -256 (minimum) -224 (black) 214 (white, 100%) 255 (maximum) 4:3 output_format_uv [1:0] w 0 uv output type selector 00 = output is 9 bit, with lsb ?ed to 0 (true 8 bit) 01 = output is 9 bit, with lsb copied from lsb + 1 10 = output is 9bit, from undithered 8 bit 11 = output is true 9 bit the output range is always interpreted as signed 2:1 output_format_y [1:0] w 0 y output type selector 00 = output is 9 bit, with lsb ?ed to 0 (true 8 bit) 01 = output is 9 bit, with lsb copied from lsb + 1 10 = output is 9bit, from undithered 8 bit 11 = output is true 9 bit the output range is always interpreted as unsigned table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-31 0 reserved - histogram measurement registers offset 0x10 ce10 histogram control register 31:27 reserved - 26 subsample_8x r/w 0 8x subsample or 4x subsample of input data 0 = 4x subsample (for standard de?ition input) 1 = 8x subsample (for high de?ition input) 25 repair_ac_error r/w 0 enable measurement on gradual slope 0 = disable (default) 1 = enable 24:17 reserved - 16:8 histo_thres [8:0] r/w 0 threshold value for the measurement algorithm (0...511) 7:4 histo_gain [3:0] r/w f 0 to 10 = gain for selection of the 8 output bits 11 to 14 = not used 15 = calculate histo_gain in hardware 3 reserved - 2 histo_noise_red r/w 1 enable / disable noise reduction feature 0 = disable 1 = enable 1 filt2_enable r/w 1 enable / disable the use of ?ter 2 0 = disable 1 = enable 0 filt1_enable r/w 1 enable / disable the use of ?ter1 0 = disable 1 = enable offset 0x10 ce18 histogram window start 31:27 reserved - 26:16 histo_xws [10:0] r/w 1 horizontal histogram measurement window start 15:11 reserved - 10:0 histo_yws [10:0] r/w 1 vertical histogram measurement window start offset 0x10 ce1c histogram window end 31:27 reserved - 26:16 histo_xwe [10:0] r/w 2d0 horizontal histogram measurement window end 15:11 reserved - 10:0 histo_ywe [10:0] r/w 120 vertical histogram measurement window end offset 0x10 ce8c histogram data output 1 31:29 reserved - 28:20 y_max [8:0] r maximum luminance value 19 reserved - 18:10 y_min [8:0] r minimum luminance value 9:8 reserved - table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-32 7:0 histo_max_value [7:0] r level of the maximum histogram data offset 0x10 ce90 histogram data output 2 31:24 histo_data_3 [7:0] r measured histogram data (bin 3, range 46...63) 23:16 histo_data_2 [7:0] r measured histogram data (bin 3, range 32...47) 15:8 histo_data_1 [7:0] r measured histogram data (bin 1, range 16...31) 7:0 histo_data_0 [7:0] r measured histogram data (bin 0, range 0...15) offset 0x10 ce94 histogram data output 3 31:24 histo_data_7 [7:0] r measured histogram data (bin 7, range 112...127) 23:16 histo_data_6 [7:0] r measured histogram data (bin 6, range 96...111) 15:8 histo_data_5 [7:0] r measured histogram data (bin 5, range 80...95) 7:0 histo_data_4 [7:0] r measured histogram data (bin 4, range 64...79) offset 0x10 ce98 histogram data output 4 31:24 histo_data_11 [7:0] r measured histogram data (bin 11, range 176...191) 23:16 histo_data_10 [7:0] r measured histogram data (bin 10, range 160...175) 15:8 histo_data_9 [7:0] r measured histogram data (bin 9, range 144...159) 7:0 histo_data_8 [7:0] r measured histogram data (bin 8, range 128...143) offset 0x10 ce9c histogram data output 5 31:24 histo_data_15 [7:0] r measured histogram data (bin 15, range 240...255) 23:16 histo_data_14 [7:0] r measured histogram data (bin 14, range 224...239) 15:8 histo_data_13 [7:0] r measured histogram data (bin 13, range 208...223) 7:0 histo_data_12 [7:0] r measured histogram data (bin 12, range 192...207) offset 0x10 cea0 histogram data output 6 31:24 histo_data_19 [7:0] r measured histogram data (bin 19, range 304...319) 23:16 histo_data_18 [7:0] r measured histogram data (bin 18, range 288...303) 15:8 histo_data_17 [7:0] r measured histogram data (bin 17, range 272...287) 7:0 histo_data_16 [7:0] r measured histogram data (bin 16, range 256...271) offset 0x10 cea4 histogram data output 7 31:24 histo_data_23 [7:0] r measured histogram data (bin 23, range 368...383) 23:16 histo_data_22 [7:0] r measured histogram data (bin 22, range 352...367) 15:8 histo_data_21 [7:0] r measured histogram data (bin 21, range 336...351) 7:0 histo_data_20 [7:0] r measured histogram data (bin 20, range 320...335) offset 0x10 cea8 histogram data output 8 31:24 histo_data_27 [7:0] r measured histogram data (bin 27, range 432...447) 23:16 histo_data_26 [7:0] r measured histogram data (bin 26, range 416...431) 15:8 histo_data_25 [7:0] r measured histogram data (bin 25, range 400...415 7:0 histo_data_24 [7:0] r measured histogram data (bin 24, range 384...399) offset 0x10 ceac histogram data output 9 table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-33 31:24 histo_data_31 [7:0] r measured histogram data (bin 31, range 496...511) 23:16 histo_data_30 [7:0] r measured histogram data (bin 30, range 480...495) 15:8 histo_data_29 [7:0] r measured histogram data (bin 29, range 464...479) 7:0 histo_data_28 [7:0] r measured histogram data (bin 28, range 448...463) noise estimation registers offset 0x10 ce20 noise estimator control register 1 31:22 reserved - 21 nest_stall w 0 stall of measurement unit 0 = measurement unit active (default) 1 = measurement unit stalled 20:19 clip_offset [1:0] w 0 selection of clipping levels 18 sel_sob_neglect_ ext w 0 selection of external sob_neglect_flag 17 sob_neglect_ext w 0 external sob_neglect ?g 16:13 compensate [3:0] w 0 signed value added to nest before low pass ?tering 12:10 gain_upbnd [2:0] w 0 selection of coupling to low boundary 9:8 ypscale [1:0] w 0 scaling factor of the pre?ter unit 7:0 wanted_value [7:0] w 46 controls the updown counting of images. when the number of times ce_sob and ce_sad are in agreement (equal ?? in an image, is smaller than wanted_value, unit are counting down; otherwise counting up. offset 0x10 ce24 noise estimator control register 2 31:24 reserved - 23:16 lb_detail [7:0] w 32 lower limit for absolute difference between two adjacent pixels 15:8 reserved - 7:0 upb_detail [7:0} w be upper limit for absolute difference between two adjacent pixels offset 0x10 ce28 noise estimator window start 31:27 reserved - 26:16 nest_xws [10:0] w 1 horizontal noise estimator window start 15:11 reserved - 10:0 nest_yws [10:0] w 1 vertical noise estimator window start offset 0x10 ce2c noise estimator window end 31:27 reserved - 26:16 nest_xwe [10:0] w 2d0 horizontal noise estimator window end 15:11 reserved - 10:0 nest_ywe [10:0] w 120 vertical noise estimator window end offset 0x10 ceb0 noise estimator data output 1 31:26 reserved - 27:24 nest [3:0] r the number of times in an image that the number of events (ce_sob = ce_sad) is lower than wanted_value. table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-34 23:16 nest_filt[7:0] r recursive ?tered nest value 15:8 detail_cnt_l [7:0] r lsbs of the number of times in an image that the difference between two adjacent pixels falls within the range of 2*lb_detail and 2*upb_detail 7:0 detail_cnt_h [7:0] r msbs of the number of times in an image that the difference between two adjacent pixels falls within the range of 2*lb_detail and 2*upb_detail offset 0x10 ceb4 noise estimator data output 2 31:9 reserved - 7:0 grey_count [7:0] r msbs of the number of pixels with values within the gray range black bar detection registers offset 0x10 ce30 black bar detector control register 31:24 bbd_event_value2 [7:0] w 10 if number of black pixels > bbd_event_value2 the line is considered as black. 23:16 bbd_slice_level2 [7:0] w 20 if luminance level < bbd_slice_level2 (multiplied by 2) the pixel is considered as black. 15:8 bbd_event_value1 [7:0] w 15 if number of black pixels > bbd_event_value1 the line is considered as black. 7:0 bbd_slice_level1 [7:0] w 55 if luminance level < bbd_slice_level1 (multiplied by 2) the pixel is considered as black. offset 0x10 ce38 black bar detection window start 31:27 reserved - 26:16 bbd_xws [10:0] w 1 horizontal black bar detection window start 15:11 reserved - 10:0 bbd_yws [10:0] w 1 vertical black bar detection window start offset 0x10 ce3c black bar detection window end 31:27 26:16 bbd_xwe [10:0] w 2d0 horizontal black bar detection window end 15:11 10:0 bbd_ywe [10:0] w 120 vertical black bar detection window end offset 0x10 ceb8 black bar detection data output 1 31:27 reserved - 26:16 bbd_last_vid_line1 [10:0] r number of last video line detected (?st detector) 15:11 reserved - 10:0 bbd_first_vid_line 1[10:0] r number of ?st video line detected (?st detector) offset 0x10 cebc black bar detection data output 2 31:27 reserved - 26:16 bbd_last_vid_line2 [10:0] r number of last video line detected (second detector) table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-35 15:11 reserved - 10:0 bbd_first_vid_line 2 [10:0] r number of ?st video line detected (second detector) black level detection registers offset 0x10 ce40 black level detection control 31:1 reserved - 0 filt1_enable w 1 enable / disable the use of ?ter1 0 = disable 1 = enable offset 0x10 ce48 black level detection window start 31:27 reserved - 26:16 bld_xws [10:0] w 1 horizontal black level detection window start 15:11 reserved - 10:0 bld_yws [10:0] w 1 vertical black level detection window start offset 0x10 ce4c black level detection window end 31:27 reserved - 26:16 bld_xwe [10:0] w 2d0 horizontal black level detection window end. pixels from xws up to and including xwe are processed. 15:11 reserved - 10:0 bld_ywe [10:0] w 120 vertical black level detection window end. lines from yws up to and including ywe are processed. offset 0x10 cec0 black level detection control / output 8:0 smartblack [8:0] r minimum luminance level uv bandwidth detection registers offset 0x10 ce50 bandwidth detection control 31:9 reserved - 8:0 max_delta_bw [8:0] w 1ff slope of the recti?r: 0: no slope 511: maximum slope (default) offset 0x10 ce58 bandwidth detection window start 31:27 reserved - 26:16 bwd_xws [10:0] w 1 horizontal bandwidth detection window start 15:11 reserved - 10:0 bwd_yws [10:0] w 1 vertical bandwidth detection window start offset 0x10 ce5c bandwidth detection window end 31:27 reserved - 26:16 bwd_xwe [10:0] w 2d0 horizontal bandwidth detection window end 15:11 reserved - 10:0 bwd_ywe [10:0] w 120 vertical bandwidth detection window end table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-36 offset 0x10 cec4 bandwidth detection output 1 31:29 reserved - 28:20 v_max [8:0] r signed maximum chrominance v value 19 reserved - 18:10 v_min [8:0] r signed minimum chrominance v value 9 reserved - 8:0 uv_bandwidth [8:0] r estimated value of bandwidth detection offset 0x10 cec8 bandwidth detection data output 2 31:29 reserved - 28:20 u_max [8:0] r signed maximum chrominance u value 19 reserved - 18:10 u_min [8:0] r signed minimum chrominance u value 9:0 reserved - interrupt and status control registers offset 0x10 cfe0 interrupt status 31:30 stat_psu[1:0] r 0 status of pixel store unit (test signal) 29:27 reserved 26:16 stat_psu_line r 0 status of pixel store unit, line currently written 15:14 stat_vsp[1:0] r 0 status of vertical scale pipe (test signal) 13:12 stat_dff[1:0] r 0 status of decimation fir ?ter (test signal) 11:10 stat_hsp[1:0] r 0 status of horizontal scale pipe (test signal) 9:8 stat_iff[1:0] r 0 status of interpolation fir ?ter (test signal) 7 stat_pfu[0] r 0 status of pixel fetch unit (test signal) 6 stat_meas_done[ r 0 status of measurement progress 5 stat_task_error r 0 processing error 4 stat_task_end r 0 current task processing done 3 stat_task_overflo w r 0 task fifo over?w 2 stat_task_idle r 0 task ?ished and the task fifo is empty. 1 stat_task_empty r 0 task fifo runs empty . 0 stat_task_done r 0 current task ?ished and all write complete. offset 0x10 cfe4 interrupt enable 31:7 reserved 6 ien_meas_done r/w measurement processing complete. 5 ien_task_error r/w 0 processing error 4 ien_task_end r/w 0 current task processing done. 3 ien_task_overflow r/w 0 task fifo over?w 2 ien_task_idle r/w 0 task ?ished and the task fifo is empty. table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 19: memory based scaler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 19-37 1 ien_task_empty r/w 0 task fifo runs empty. 0 ien_task_done r/w 0 current task ?ished and all write complete. offset 0x10 cfe8 interrupt clear 31:7 reserved 6 clr_meas_done w measurement processing complete. 5 clr_task_error w 0 processing error 4 clr_task_end w 0 current task processing done. 3 clr_task_overflo w w 0 task fifo over?w 2 clr_task_idle w 0 task ?ished and the task fifo is empty. 1 clr_task_empty w 0 task fifo runs empty. 0 clr_task_done w 0 current task ?ished and all write complete. offset 0x10 cfec interrupt set 31:7 reserved 6 set_meas_done w measurement processing complete. 5 set_task_error w 0 processing error 4 set_task_end w 0 current task processing done. 3 set_task_overflo w w 0 task fifo over?w 2 set_task_idle w 0 task ?ished and the task fifo is empty. 1 set_task_empty w 0 task fifo runs empty. 0 set_task_done w 0 current task ?ished and all write complete. offset 0x10 cff4 powerdown 31 power_down rw 0 0 = normal operation 1 = powerdown mode 30:0 reserved offset 0x10 cffc module id 31: 16 mod_id r 0119 module id; unique 16-bit code 15: 12 rev_major r 0x2 major revision counter 11: 8 rev_minor r 0x8 minor revision counter 7: 0 app_size r 0 aperture size: 0 = 4kb table 8: memory based scaler (mbs) registers ?ontinued bit symbol acces s value description
1. introduction the purpose of this module is to accelerate the 2d drawing operations that are most heavily used in a graphics environment. the 2d drawing engine (2dde or de in the following text or data book) interfaces with both the internal mmio-dtl bus and the internal memory bus. de operation may be synchronous to the memory interface, with a small portion of the module operating at the mmio bus clock frequency. 1.1 features the major features of the 2d drawing engine are: high speed operation 3 operand bit blt (256 raster operations) alpha blending transparent bit blt fast host monochrome to full color expansion for text, mono bitmaps, and patterns lines 2. functional description a block diagram of the 2d drawing engine is shown in figure 1 . chapter 20: 2d drawing engine pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-2 2.1 2d drawing engine block level diagram 2.2 architecture 2.2.1 registers this block contains the mmio registers for the drawing engine. 2.2.2 host interface this block synchronizes and fifos data from the internal mmio bus. host data and patterns pass through this block as well as register operations. 2.2.3 color expand monochrome bitmaps, fonts, and patterns pass through this block and are expanded to the appropriate full color depth. the color expanded data will then be sent to the rotator block for alignment or loaded into the pattern ram. full color data also passes through this block and is combined from dword s into qwords. alpha data from the host is converted to the appropriate format by this block. figure 1: 2d drawing engine block diagram internal mmio bus host interface color expand rotator source fifo dest fifo pattern fifo write datapath memory read data foreground transparency byte masking control address byte enables write data memory i/f gizmo source state dest state bit blit engine vector engine registers address stepper memif interface
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-3 2.2.4 rotator this module aligns source data to the destination. 2.2.5 source fifo this structure can hold up to 256 bytes of source data. source data may be provided from either frame buffer memory or the host processor via the mmio bus. data in this fifo will always be aligned to the destination. the output of this fifo is used as the source operand for rops and is also used when transparency is dependent on the source. 2.2.6 pattern fifo this structure can hold up to 256 bytes of pattern data. pattern data is always locked to screen position and therefore never needs to be aligned. this fifo can hold one 8 x 8 pattern in true color, 2 patterns in high color, and 4 patterns in pseudo-color mode. this fifo will contain the foreground color value if solid patterns are enabled. the output of this fifo is used as the pattern operand for rops. transparency on patterns is not allowed. 2.2.7 destination fifo this structure can hold up to 256 bytes of destination data. destination data is required when a rop requires the contents of the frame buffer to be combined with source data, pattern data, or both. destination data is by de?ition always aligned and therefore does not need to be rotated. the output of this fifo is used as the destination operand for rops and is also used when transparency is dependent on the destination. 2.2.8 write datapath the write datapath includes the rop, alpha blending, and color compare functions. the output of this block is the 64-bit data to be sent to the memory. 2.2.9 source state this block maintains the current state of the source address while the address stepper is processing the destination address. 2.2.10 destination state this block maintains the current state of the destination address while the address stepper is processing the source address. it also may maintain dst reads while dst writes are occurring, or vice versa. 2.2.11 address stepper this block is responsible for the calculation of the addresses required for a given operation. the output of this block provides the address to the mtc and provides byte masking information to the byte mask block.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-4 2.2.12 bit blt engine this is the main control logic for bit blt commands. this block breaks blts down into appropriate subcommands such as src read, dst write, etc. and then sequences through those subcommands. 2.2.13 vector engine this is the main control for line commands. this block contains the bresenham engine. 2.2.14 memory interface this block handles the interface to the dvp memory highway gizmo. 2.2.15 byte masking this block combines bit blt or vector byte mask information and transparency information to generate the byte enables for the mtc. this block also generates the block write masks. 2.3 general operations the drawing engine supports two types of operations: lines and bit blts. line capability is limited to solid lines, with the software responsible for the calculation of the initial error terms of the bresenham algorithm. lines are provided as a compatibility check mark and are not highly optimized. bit blts are the primary function of the drawing engine and are highly optimized for performance. bit blt is the generic term used to indicate the transfer and processing of a block of visual data from one location to another. to specify the type of bit blt, the following information is required: raster operation (rop): of 256 possible rops alpha blend mode: source or surface source data location and type: system memory or cpu, mono, color, or alpha transparency: on source, on destination, or none pattern: 8 x 8 mono, 8 x 8 color, or solid 2.3.1 raster operations the drawing engine supports a three operand bit blt. the three operands are source, destination, and pattern. there are eight logical operations that can be performed with any combination of the three operands: one, zero, and, or, nand, nor, xor, nxor. this yields a total of 256 combinations of rop that can be performed. although all 256 rops are possible, only a handful of these rops are typically used. examples of a single operand blt would be a pattern ?l or a basic screen-to-screen copy where the source overwrites the destination. an example of a two operand blt is the source is ?ord?with the destination. a three operand blt could ?nd?the source, pattern, and destination. the raster operation is de?ed by an 8-bit ?ld specifying one of the possible 256 operations.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-5 raster-ops are turned off if alpha blending is enabled. 2.3.2 alpha blending the drawing engine supports alpha blending of source and destination data. the destination data can be either 32-bit rgb:8888, 32-bit yuv8888, 16-bit rgb:565, 16-bit argb 4444, or 16-bit rgba 4534. source data can come either from the memory or from the host data port. the alpha calculations are based on the source and "surface" alpha values. raster-ops are disabled if alpha blending is selected. the following combinations of source and destination data are supported. 2.3.3 source data location and type the data for the source operand can reside in either the frame buffer memory or be provided by the host processor via the mmio bus. there are ?e source selection options currently de?ed: 1. source data is held in frame buffer memory (always full color data) 2. source data is provided by the processor via the mmio bus and is full color 3. source data is provided by the processor via the mmio bus and is a monochrome bitmap table 1: source and destination data source source format destination format notes memory rgb:8888 rgb:8888 std alpha calculations host rgb:8888 rgb:8888 std alpha calculations host :4 rgb:8888 monohostbcolor reg provides src color host :8 rgb:8888 monohostbcolor reg provides src color memory rgb:565 rgb:565 surface reg speci?s alpha host rgb:565 rgb:565 surface reg speci?s alpha host :4 rgb:565 monohostbcolor reg provides src color host :8 rgb:565 monohostbcolor reg provides src color memory rgb :4534 rgb :4534 std alpha calculations host rgb :4534 rgb :4534 std alpha calculations host :4 rgb :4534 monohostbcolor reg provides src color host :8 rgb :4534 monohostbcolor reg provides src color memory rgb:4444 rgb:4444 std alpha calculations host rgb:4444 rgb:4444 std alpha calculations host :4 rgb:4444 monohostbcolor reg provides src color host :8 rgb:4444 monohostbcolor reg provides src color
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-6 4. source data is provided by the processor via the mmio bus and is a monochrome text font. 5. source data is provided by the processor via the mmio bus and is alpha blending data. option 1 is used for normal screen-to-screen operations such as a source-to- destination copy. option 2 is used for a host-to-screen copy when the source data is a full color bitmap. option 3 is used for color expanding a monochrome bitmap. the monochrome bitmap will be expanded to full color using the foreground and background color registers within the drawing engine. option 4 is similar to option 3 except that it is designed to handle tightly packed fonts, which are used to render text. a three-bit ?ld is used to select the appropriate source data option. option 5 is similar to option 2 except that the data provided on the mmio bus is either packed 4 bit alpha or packed 8-bit alpha information. 2.3.4 patterns the drawing engine provides an 8-by-8 pattern or ?rush.?the pattern is always locked to the screen. this pattern can be solid, monochrome, or full color. if the pattern is solid, the color value will be taken from the foreground color register. a monochrome pattern is stored in system memory as two dword s (64 bits) of monochrome data. this monochrome data is written to the drawing engine where it is color expanded to the appropriate color depth and stored in the pattern ram. a full color pattern will be directly transferred from system memory into the pattern ram. only one pattern may be stored in the pattern ram at a given time. 2.3.5 transparency the drawing engine supports transparency on either source or destination data. transparent patterns are not supported. transparency works by comparing either source or destination to a value stored in a color compare register and then allowing (or disallowing) a write to occur based on the result of the compare. transparency is implemented on a per-pixel basis: at 8 bpp one byte is used for the compare value. at 16 bpp one word is used for the compare, and at 32 bpp the entire color compare register is used for the compare. a transparency mask is provided in order to exclude certain bits within a pixel from being used in the color compare. 2.3.6 block writes block writes are not supported by the drawing engine. 3. operation 3.1 register programming guidelines 3.1.1 alpha blending the drawing engine supports alpha blending of source, destination, and a global surfacealpha. the following destination formats are useful with alpha blending: rgb:565(16 bit per pixel) rgb:4444(16 bit per pixel)
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-7 rgb :4534(16 bit per pixel) rgb:8888(32 bit per pixel) yuv:8888(32 bit per pixel, full range) yuv:8888(32 bit per pixel, d1 range) destination pixels always reside in memory. source pixels may either come from memory (if they are in the same color format as the destination) or from the host data port. in addition to accepting pixels in the destination format, the host data port also accepts 4 or 8-bit alpha values. in this case, the color values for each source pixel come from the monohostbcolor register (address 1424h). the source pixels may contain either ?ormal?or ?re-multiplied?color values. if the source pixel is pre-multiplied, the alpha value in the source pixel is not applied to the source pixel. ?ormal?color values will have the source alpha applied. in addition to blending source and destination data using the sources alpha, the drawing engine also has a global ?urface alpha.?the surface alpha is applies to all pixels in a alpha blt. surface alpha is stored in the monohostfcolor register (address 1420h). two ayuv:8888 formats are supported. one of the formats (pformat=1) assumes full range yuv data i.e., 0xff..0x00. the other format, (pformat=2) assumes the normal d1 limited range of values: y:235:16, u/v:240:16. the following algorithm describes the alpha blending data ?w. we assume that all values have been normalized to a range of 1..0. in reality, this will be represented by actual values of 0xff..0x00.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-8 // fetch a source pixel into src if (bltctl.src == 0) // fetch src pixel from system memory .... else if (bltctl.src == 1) // src data is color from cpu src= hostdata[31:0] else if (bltctl.src == 4) begin // fetch 4 bits of alpha from host, expand to 8 bits src.alpha = (hostdata[3:0] << 4) | hostdata[3:0] ; src.red = halphacolor.red src.green = halphacolor.green src.blue = halphacolor.blue end else if (bltctl.src == 5) begin // fetch 8 bits of alpha from host src.alpha = hostdata[7:0] ; src.red = halphacolor.red src.green = halphacolor.green src.blue = halphacolor.blue end else if (bltctl.src == 6) // set src to 1 if no src data. begin src.red = halphacolor.red src.green = halphacolor.green src.blue = halphacolor.blue src.alpha = halphacolor.alpha end // copy mono foreground info into the surfalpha surfalpha = monohostfcolor // handle src bitmaps without alpha values if (bltctl.a[1:0] == 3 || (pixelsize==16 && pformat == 0) ) src.alpha = 1; // handle non-premultiplied source pixels if (bltctl.a[1:0] == 1) begin src.red *= src.alpha ; src.green *= src.alpha ; src.blue *= src.alpha ; end // scale the src with the surface alpha values src.red *= surfalpha.red; src.green *= surfalpha.green; src.blue *= surfalpha.blue; src.alpha *= surfalpha.alpha
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-9 alpha values in 32-bit pixels are always in the upper byte of the dword . 3.1.2 mono expand the engine needs to deal with two types of monochrome data from the host: fonts and bitmaps. the primary difference between fonts and bitmaps is how data is padded to byte boundaries. first, it is worthwhile to note the bit ordering of monochrome data in a dword .bit7is the left most pixel, bit 24 is the right most pixel. it is (unfortunately) a mish-mash of data formats since pixels in a byte are big-endian, but bytes are little-endian ordered. thus, in a dword , bits are processed in the following order: bit7, bit6, bit5,... bit0, bit15, bit4f4... bit8, bit 23... bit16, bit31... bit24 fonts can be transferred to the drawing engine in a highly packed format with no pad data between bits on adjacent scanlines. pad is added after the last bits in the last data byte. since the font data in system memory always begins on a byte boundary, the host processor can easily arrange to deliver a series of 32-bit aligned dword s to the engine. this font format has been widely used by microsoft since windows 95. // now update the destination if (bltctl.a[3] == 0) begin dst.red = clamp(src.red + (1 ?src.alpha) * dst.red) ; dst.green = clamp(src.green + (1 ?src.alpha) * dst.green) ; dst.blue = clamp(src.blue + (1 ?src.alpha) * dst.blue) ; // optionally update the dst alpha if (bltctrl.a[2]) dst.alpha = clamp(src.alpha + (1 ?src.alpha) * dst.alpha); end else begin dst.red = clamp(src.red); dst.green = clamp(src.green); dst.blue = clamp(src.blue); // optionally update the dst alpha if (bltctrl.a[2]) dst.alpha = clamp(src.alpha) end
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-10 in the following example, the data stream for a 5*6 font requires 1 dword to be sent to the engine. since font data starts on a byte boundary, a source shift parameter is not required. the width ?ld of the bltsize register determines how many host bits will be processed before advancing to the next scanline. there are no pad bits between data bits of adjacent scanlines - the data is highly packed. excess bits in the very last dword of host data will be discarded. the engine will require (bltsize.width*bltsize.height +31)/32 dwords for each glyph drawn. mono bitmaps sent to the engine from windows are not necessarily byte aligned on the left or right edges. the starting and ending bits of each scanline may be in the middle of a byte. for mono bitmaps, the ?e lsbs of the srclinear register determine which bit in the ?st dword has the ?st valid data bit. the bltsize.width register determines how many bits will be expanded/drawn for each scanline. the host will send (bltsize.width + (srclinear&31) + 31)/32 dword s for each scanline. the engine will discard unused bits in the last dword of each scanline as pad bits. the driver must always send the correct number of dword s for each scanline in the bitmap. 3.1.3 mono blt register setup to deal with both host-to-screen mono bitmap and text data in a general manner, the engine uses up to eight parameters as shown in t ab le 2 . 31 0 d ata stream:00110001001001111010000110000110 rendered font: 10000 11010 10000 10010 01110 01100 note the 2 pad bits (25 & 24) in the last byt e. table 2: mono bitmap & text data parameters parameter description dstxy or dstlinear speci?s the drawing destination on the screen srclinear the three lsbs specify the leading pad bits in the ?st byte of data on each scanline. dststride speci?s the number of pixels between scanlines in the destination monohostfcolor foreground color monohostbcolor background color
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-11 when the bltctl.src register is set for font rendering (3), the engine automatically accommodates the prede?ed padding and alignment requirements for fonts. this means that the host data will be tightly packed with no padding between scanlines or before the very ?st pixel. after the ?st font glyph has been sent from the host, only two registers will need to be re-loaded to initiate the next text blt: dstxy/dstlinear and bltsize. 3.1.4 solid fill setup solid ?l is a common graphics operation. to achieve low programming overhead, the drawing engine only uses ?e parameters to set up a solid color ?l. 3.1.5 color blt setup the engine uses up to 10 parameters to set up a color blt. cccolor color compare color for transparency bltctl drawing function bltsize destination width and height table 2: mono bitmap & text data parameters ?ontinued parameter description table 3: solid color fill parameters parameter description dstxy or dstlinear speci?s the drawing destination on the screen dststride speci?s the number of pixels between scanlines in the destination monopatfcolor speci?s the drawing color. bltctl this register indicates that a solid ?l operation is desired by setting the src ?ld to 5, cc ?ld to 0. the rop ?ld is a don? care. bltsize speci?s destination width and height, initiates drawing function. table 4: color blt parameters parameters description dstxy or dstlinear speci?s the drawing destination on the screen. srcxy or srclinear speci?s the location of source data for screen-to-screen blts. speci?s start of line alignment for host-to-screen operations. srcstride speci?s the number of pixels between scanlines in the source for screen- to-screen blts. unused for host-to-screen blts. dststride speci?s the number of pixels between scanlines in the destination. monopatfcolor speci?s the drawing color for solid ?l blts using block write. also may be used to load the patram quickly. monopatbcolor the background color register may be used to help load the patram quickly. cccolor the color compare color may be loaded if transparency is enabled in the bltctl register.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-12 simple screen-to-screen blts use four registers to initiate the operation: srcxy/ srclinear, dstxy/dstlinear, bltctl, and bltsize. this assumes that the stride registers have already been initialized with the current screen pitch. simple color host-to-screen blts use four registers to initiate the operation: dstxy/ dstlinear, srcxy/srclinear, bltctl, and bltsize. this assumes that the dststride register has already been initialized with the current screen pitch. the srcxy/srclinear register speci?s the data alignment at the start of each scanline. the ?st dword of data will have (srclinear & 3) pixels of pad data in the least signi?ant bytes. each scanline of host data is padded to end on a dword boundary. the engine will draw bltsize.width pixels for each scanline of the blt. the number of dword s of host data for each scanline is ((bltsize.width + (srclinear & 3) )*(psize/8) + 3)/4 advanced blts will initialize a small group of additional registers. if transparency is desired, the color compare color and transparency mask registers are loaded. if patterns are used, the dstxy register and the patram (see below) must be loaded. the pattern is usually tiled to the screen assuming the upper left corner of the pattern is anchored to the upper left corner of the screen. to easily do this, the three low bits of the x and y ?lds of the dstxy register are used to derive the initial alignment of the pattern data. the pattern register can be ?n-anchored?by ?st writing to the dstxy register to specify the pattern alignment, then writing the dstlinear with the actual destination screen address. the last write to the dstxy register will set the pattern alignment. this means that you must always load the dstxy register before starting a blt that uses the pattern. 3.1.6 patram the patram is an 8*8 pixel pattern cache that provides pattern data for the rop alu. the patram operates at either 8, 16, or 32 bits per pixel as speci?d in the psize register: in 8 bit per pixel mode, only the ?st 64 bytes of the patram are used. the host must initialize bytes 0 to 63 prior to initiating a blt that uses a pattern. in this mode, byte 0 of the patram is the upper left pixel in the ram. in 16 bit per pixel mode, only the ?st 128 bytes of the patram are used. the host must initialize bytes 0 to 127 prior to initiating a blt that uses a pattern. in this mode, bytes 0 and 1 of the patram are the upper left pixel in the ram. byte 0 is the lsb of the pixel and contains ?e bits of the blue component and three bits of the green component. byte 1 contains the remaining bits of the green component and ?e bits of the red component. transmask the transparency mask is used to mask out bits for color compare operations. bltctl drawing function: rop type, color compare enables, source data path bltsize speci?s destination width and height, initiates drawing function. table 4: color blt parameters ?ontinued parameters description
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-13 in 32-bit per pixel mode, all 256 bytes of each scanline of the patram are used. the host must load the entire patram prior to initiating a blt that uses a pattern. in this mode, bytes 0..3 of the patram are the upper left pixel in the ram. byte 0 is the lsb of the pixel and contains the blue component, byte 1 contains the green component, byte two contains the red component, and byte three is the alpha component (usually unused). the patram can be loaded in two different ways to load either color data or monochrome data. the 256 byte patramcolor section of the register space allows direct byte/word/ dword access to the patram. this allows arbitrary pattern data to be loaded. 64 pixels of data must be loaded into the patram prior to use. this ranges from 64 to 256 bytes of data depending on color depth. byte 0 of this space is the ?st byte of patram scanline 0. to assist in loading mono patterns, the 8 byte patrammono section of the register space provides automatic color expansion of mono data while loading the patram. thus, the host only sends 16 bytes (four dwords ) of data to initialize the entire pattern regardless of color depth: monpatfcolor, monopatbcolor, and 8 bytes of mono data (64 bits). each bit in the mono data stream loads the appropriate byte(s) of the patram with either the foreground color if the bit is a 1, or else the background color if the bit is a 0. byte0/bit7 loads the left pixel of scanline 0, byte1/bit7 loads the left pixel of scanline 1, etc. 4. register descriptions the drawing engine uses ?e areas of memory space: 1. the ?st memory space area is for the drawing engine command registers. these registers are used to set up and execute drawing engine commands. there is a block of unused memory space that has been reserved for future drawing engine functions. 2. the next area decoded is for monochrome pattern data. although only 8 bytes of monochrome pattern data are required, a 256-byte decode is implemented to allow color expansion to occur to different areas of the pattern ram. 3. the third decoded area is for full color pattern data. 64, 128, or 256 bytes of data may be written to the pattern ram. 4. the fourth area decoded is for ?eal time?drawing registers. unlike command registers which are pipelined, real time registers can be accessed immediately. 5. the last memory area decoded is a 64-kb area that is used to transfer host data to the drawing engine.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-14 the addresses in the following table are offsets from the mmio aperture base. 4.1 register summary table 5: 2de memory space addresses offset range decoded for 0x04,f400 - 0x04,f47f 0x04,f5f8 ?0x04,f5ff drawing engine command registers 0x04,f480 ?0x04,f5f7 reserved for future use 0x04,f600 - 0x04,f6ff monochrome pattern data 0x04,f700 - 0x04,f7ff color pattern data 0x04,f800 - 0x04,f80b real time drawing engine registers 0x05,0000 - 0x05,ffff drawing engine host data table 6: 2d command registers offset symbol description 0x04 f400 srcaddrbase src base address for xy->linear 0x04 f404 dstaddrbase dst base address for xy->linear 0x04 f408 psize color depth for drawing operations 0x04 f40c srclinear blt src address (linear) 0x04 f410 dstlinear vector/blt dst address (linear) 0x04 f414 srcstride scanline src pitch for blts 0x04 f418 dststride scanline dst pitch for blts/vectors 0x04 f41c cccolor color compare target 0x04 f420 monohostfcolor and surfalpha foreground color for mono host expansion, surfalpha register for alpha blending 0x04 f424 monohostbcolor and halphacolor background color for mono host expansion, color value for host alpha data for alpha blending 0x04 f428 bltctl raster op, etc. selection 0x04 f42c srcxy blt src address (xy) 0x04 f430 dstxy vector/blt dst address (xy) 0x04 f434 bltsize b lt size (width and height) initiates blt drawing 0x04 f438 dstxy2 vector/blt dst address (xy) 0x04 f43c vecconst vector bresenham constants 0x04 f440 veccount vector length, octant, error term. initiates line drawing 0x04 f444 transmask transparency mask
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-15 4.2 register tables 0x04 f448 0x04f5f4 reserved reserved for future use 0x04 f5f8 monopatfcolor foreground color for mono pattern expansion, lines, and solid ?ls 0x04 f5fc monopatbcolor background color for mono pattern expansion, lines, and solid ?ls table 7: 2d real time drawing registers offset symbol description 0x4f600 0x4f6ffc patrammono monochrome pattern cache ram 0x4f700 0x4f7ffc patramcolor full color pattern cache ram 0x4f800 enginestatus status control of the engine 0x4f804 panic control reset 0x4f808 enginecon? interrupt con?uration 0x4f80c hostfifostatus number of entries in the host fifo 0x4 f810 0x4fff0 reserved reserved for future use 0x4fff4 powerdown powerdown activation 0x4fffc deviceid module id and aperture size 0x50000 0x5fffc hostdata 64kb memory space for the host table 6: 2d command registers ?ontinued offset symbol description table 8: registers description bit symbol acces s value description 2d command registers offset 0x04 f400 source address base 31:29 swap[2:0] r/w - speci?s endian-swapping on reads from memory. when swap[2] is 0, swapping is determined by the global endian setting, possibly modi?d by bsi[0] in enginecon?. when swap[2] is 1, swapping is determined by swap[1:0] as shown: 00=no swapping. memory is little-endian. 01=bytes are swapped within each 16-bit word. 10=words are swapped within each 32-bit double word. 11=bytes are swapped within each 32-bit double word. 28:24 reserved
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-16 this register speci?s the offset for pixel (0,0) of a source bitmap for xy to linear conversion of addresses. this register is interpreted as a byte address. the lower three bits of this register always read 0, regardless of the value written. this implies that the source base address must be aligned to a 64-bit boundary. under many circumstances, this register will be initialized to the proper offset and then changed only for special effects. this register speci?s the offset for pixel (0,0) of a destination bitmap for xy to linear conversion of addresses. this register is interpreted as a byte address. the lower three bits of this register are always interpreted as 0, regardless of the value written. when reading the contents of this register, the lower three bits will be read back as 0. this implies that the source base address must be aligned to a 64-bit boundary. under many circumstances, this register will be initialized to the proper offset and then changed only for special effects. 23:16 off[22:16] r/w - speci?s the offset for pixel (0,0) of a source bitmap for xy to linear conversion of addresses. bits 2:0 must be set to 0. 15:8 off[15:8] r/w - 7:0 off[7:0] r/w - table 8: registers description bit symbol acces s value description table 9: destination address base bit symbol acces s value description offset 0x04 f404 destination address base 31:29 swap[2:0] r/w - speci?s endian-swapping on reads from memory. when swap[2] is 0, swapping is determined by the global endian setting, possibly modi?d by bsi[0] in enginecon?. when swap[2] is 1, swapping is determined by swap[1:0] as shown: 00=no swapping. memory is little-endian. 01=bytes are swapped within each 16-bit word. 10=words are swapped within each 32-bit double word. 11=bytes are swapped within each 32-bit double word. 28:24 reserved 23:16 off[22:16] r/w - specify the offset for pixel (0,0) of a destination bitmap for xy to linear conversion of addresses. bits 2:0 must be set to 0. 15:8 off[15:8] r/w - 7:0 off[7:0] r/w -
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-17 this register speci?s the pixel size and format for the drawing engine for blts and vectors. this register is unchanged by any drawing operations. the t ab le 11 shows the pixel bit assignments for each of the six color formats above. note that in the 4534 case, the format name is not indicative of the actual order of the bits. the yuv values have ranges which match the d1 format in the ccir 656. y is an unsigned value ranging from 16 to 235. u and v are signed offset values ranging from 16 to 240, where 128 represents the zero point. table 10: pixel size bit symbol acces s value description offset 0x04 f408 pixel size 31:16 reserved 15:8 pformat[7:0] r/w 3 currently used only during alpha-blending operations. the format is dependent on the color depth. refer to t ab le 11 below for bit assignments. 16 bpp: 0000_0000rgb 565 0000_0001 rgb 4444 0000_0010rgb 4534 0000_1000rgb 565 dithered 0000_1001 rgb 4444 dithered 0000_1010rgb 4534 dithered 32 bpp: 0000_0000 rgb 8888 0000_0001 vyu 8888 0000_0010 yuv 8888 note: specifying any other combination of bits will result in an invalid command being executed. 7:0 depth[5:0] r/w 08 speci?s the number of bits per pixel. 00100000b32 bpp 00010000b16 bpp 00001000b8 bpp all other values are reserved. table 11: pixel format bit assignments format 31 24 23 16 15 8 7 0 rgb 565 rrrrrggg gggbbbbb rgb 4444 aaaarrrr ggggbbbb rgb 4534 aaaarrrr gggggbbb rgb 8888 aaaaaaaa rrrrrrrr gggggggg bbbbbbbb vyu 8888 aaaaaaaa vvvvvvvv yyyyyyyy uuuuuuuu yuv 8888 aaaaaaaa yyyyyyyy uuuuuuuu vvvvvvvv
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-18 when depth is 16, pformat[3] enables dithering the results of an alpha blend operation. all alpha blend operations are done with 8 bits of precision for each component. the components of the source pixels are expanded to 8 bits by replicating the high-order bits into the low-order bits. the results of the computations can be thought of as being in ?ed point, with 3, 4, 5 or 6 bits of precision to the left of the decimal point, depending on the component and color format. when dithering is enabled, a 4x4 dither is applied by adding a constant fraction to each component and truncating the results to ? in the resulting pixel. the constant fraction is taken from the following table, based on the x and y coordinates of the destination pixel. this register is used to load the linear source address for a blt operation. it must be loaded with a pixel aligned address. note that loading the srcxy register actually causes this register to be loaded with the proper linear pixel address. this register is interpreted as a byte address, except during a monochrome host to screen bit blt, or a 4-bit or 8-bit expand alpha blt. in the monochrome blt case, adr[4:0] speci?s the ?st valid bit within the ?st dword transferred by the host. adr[4:3] speci?s the correct byte and adr[2:0] specify the correct bit. in the 4-bit expand case, adr[3:0] speci?s the ?st valid nibble within the alpha data transferred by the host. in the 8-bit expand case, adr[2:0] speci?s the ?st valid byte within the alpha data transferred by the host. this register is unchanged by drawing operations. table 12: dithering format x mod 4 = 0 x mod 4 = 1 x mod 4 = 2 x mod 4 = 3 y mod 4 = 0 7/8 3/8 1/8 5/8 y mod 4 = 1 1/8 5/8 7/8 3/8 y mod 4 = 2 5/8 7/8 3/8 1/8 y mod 4 = 3 3/8 1/8 5/8 7/8 table 13: source linear bit symbol acces s value description offset 0x04 f40c source linear 31:24 reserved 23:16 adr[22:16] r/w - used to load the linear source address for a blt operation. 15:8 adr[15:8] r/w - 7:0 adr[7:0] r/w - table 14: destination linear bit symbol acces s value description offset 0x04 f410 destination linear 31:24 reserved 23:16 adr[22:16] r/w 0 used to load the starting linear pixel address for a vector or the destination linear address for a blt operation. 15:8 adr[15:8] r/w 0 7:0 adr[7:0] r/w 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-19 this register is used to load the starting linear pixel address for a vector or the destination linear address for a blt operation. it is interpreted as a byte address and must be loaded with a pixel aligned address. note that loading the dstxy register actually causes this register to be loaded with the proper linear pixel address. this register may not be used to specify the destination address for a command that utilizes patterns. this register holds the unsigned offset between adjacent source scanlines for screen- to-screen blts. under many circumstances, this register will be initialized to the screen pitch and then changed only for special effects. this 14-bit register is interpreted as an unsigned byte value. it is used during a blt to step from scanline to scanline. it is also used to convert a srcxy address to a srclinear address according to the following formula: srclinear = srcxy.y * srcstride + srcxy.x (1) + srcaddrbase (1) this value is adjusted for pixel color depth. there are no restrictions on this register except that the lower three bits are always interpreted as 0, regardless of the value written. when reading the contents of this register, the lower three bits will be read back as 0. this implies the source stride must be a multiple of 8 bytes. as this is an unsigned register, it is always interpreted as a positive value. the direction in which a source is traversed is controlled by the blt direction ?ld in the bltctl register. this register may be useful for blting bitmaps stored in off screen memory in a 1d format to the screen. it is unchanged by any drawing operations. table 15: source stride bit symbol acces s value description offset 0x04 f414 source stride 31:14 reserved 13:0 srcstr r/w 0x3ff8 used to load the starting linear pixel address for a vector or the destination linear address for a blt operation. bits 2:0 must be set to 0. table 16: destination stride bit symbol acces s value description offset 0x04 f418 destination stride 31:14 reserved 13:8 dststr[13:8] r/w 0 hold the offset between adjacent scanlines for blts and vectors. bits 2:0 must be set to 0. 7:0 dststr[7:0] r/w 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-20 this register holds the offset between adjacent scanlines for blts and vectors. under many circumstances, this register will be initialized to the screen pitch and then changed only for special effects. it is interpreted as an unsigned byte value. this 14-bit signed register is used during blts and vectors to step from scanline to scanline. it is also used to convert a dstxy address to a dstlinear address according to the following formula: dstlinear = dstxy.y * dststride + dstxy.x (1) + dstaddrbase (1) this value is adjusted for pixel color depth there are no restrictions on this register except that the lower three bits are always interpreted as 0, regardless of the value written. when reading the contents of this register, the lower three bits will be read back as 0. this implies that the destination stride must be a multiple of 8 bytes. as an unsigned register, it is always interpreted as a positive value. the direction in which the destination is traversed is controlled by the blt direction ?ld in the bltctl register. this register may be useful for blting bitmaps stored in offscreen memory in a 1d format to the screen. it is unchanged by drawing operations. this register holds the color compare target color. this register should be initialized prior to any blt that enables color compare. the appropriate number of bytes needs to be loaded in accordance with the current color depth. thus, if the current depth is 8 bits, only the lowest byte need be written. if the depth is 16 bits, the lowest two bytes need to be written. when reading the value of this register, the lower byte will be replicated in all four byte lanes in 8 bpp mode. in 16 bpp mode, the lower word will be replicated into the upper word. in 32 bpp mode, all bits are unique and will read back the 32-bit data that was written. this register is unchanged by drawing operations. table 17: color compare bit symbol acces s value description offset 0x04 f41c color compare 31:24 cccol[31:24] r/w 0 holds the color compare target color. 23:16 cccol[23:16] r/w 0 15:8 cccol[15:8] r/w 0 7:0 cccol[7:0] r/w 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-21 this register holds the foreground color for host bitmap monochrome expansion. the appropriate number of bytes need to be loaded in accordance with the current color depth. thus, if the current depth is 8 bits, only the lowest byte need be written. if the depth is 16 bits, the lowest two bytes need to be written. when used as surfalpha, this register always contains four unsigned 8-bit alpha values, regardless of color depth. note: when reading the value of this register, the lower byte will be replicated in all four byte lanes in 8 bpp mode. in 16 bpp mode, the lower word will be replicated in the upper word. in 32 bpp mode, all bits are unique and will read back the 32-bit data that was written. this register is unchanged by drawing operations. this register holds the background color for host bitmap monochrome expansion. the appropriate number of bytes need to be loaded in accordance with the current color depth. thus, if the current depth is 8 bits, only the lowest byte need be written. if the depth is 16 bits, the lowest two bytes need to be written. when used as hostalphacolor, the least signi?ant three bytes of this register always contain 8-bit color values, regardless of the current depth. the most signi?ant byte is supplied by the expanded host data during a 4-bit or 8-bit alpha expand blt. in the yuv formats, the order of the components in the least signi?ant three bytes matches that of the current pformat. when reading the value of this register, the lower byte will be replicated into all four byte lanes in 8 bpp mode. in 16 bpp mode, the lower word will be replicated into the upper word. in 32-bpp mode, or when a[3:0] in bltctl are non-zero, all bits are unique and will read back the 32-bit data that was written. this register is unchanged by drawing operations. table 18: mono host f color or surfalpha bit symbol acces s value description offset 0x04 f420 mono host f color or surfalpha 31:24 fcol[31:24]alpha[7:0] r/w 0 speci?s the foreground color for host bitmap monochrome expansion. for alpha-blending, this register speci?s the global surface alpha values. 23:16 fcol[23:16]r/v/y[7:0] r/w 0 15:8 fcol[15:8]g/y/u[7:0] r/w 0 7:0 fcol[7:0]b/u/v[7:0] r/w 0 table 19: mono host b color or halpha color bit symbol acces s value description offset 0x04 f424 mono host b color or halpha color 31:24 bcol[31:24] r/w 0 hold the background color for host bitmap monochrome expansion. for alpha-blending this register may provide color data. 23:16 bcol[23:16]r/v/y[7:0] r/w 0 15:8 bcol[15:8]g/y/u[7:0] r/w 0 7:0 bcol[7:0]b/u/v[7:0] r/w 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-22 table 20: blt control bit symbol acces s value description offset 0x04 f428 blt control 31:27 reserved 26:24 bd[2:0] r/w 0 the bd[2:0] ?ld speci?s the bitblt direction. bd[0] speci?s the horizontal blt direction. it is bit 24 of this register: 0 = blt direction is left to right. 1 = blt direction is right to left. bd[1] speci?s the vertical blt direction. it is bit 25 of this register: 0 = blt direction is top to bottom. 1 = blt direction is bottom to top. bd[2] enables vertical ?pping during the blt by allowing the source data to be read in the opposite vertical direction from the destination data. bd[2] is bit 26 of this register: 0 = src is read as speci?d in bd[1.] 1 = src is read in reverse of bd[1]. 23:20 a[3:0] r/w 0 the a[3:0] ?ld controls alpha-blending operations and is in bits 23:20 of this register. a[1:0] controls enabling of alpha-blending and the format of the source data. the valid values are: 0 = alpha-blending is disabled. 1 = src data contains normal alpha data. 2 = src data contains pre-multiplied alpha data. 3 = src data does not have alpha data, surface alpha is the only alpha value. bit 2 of this ?ld controls the updating of the alpha ?ld in the destination: 0 = preserve destination alpha ?ld. 1 = update destination alpha ?ld. bit 3 of this ?ld controls whether destination data participates in the alpha blend operation. it is used to implement ?nary?blends: 0 = blend source with destination data 1 = blend source with black in rgb mode, black means rgb = (0, 0, 0). in yuv mode, black means yuv = (16, 128, 128). 19 reserved 18:16 cc[2:0] r/w 0 the cc[2:0] speci?s the operation of the color compare hardware. cc[2:0] are bits 19:16 of this register. legal values are: 0 = color compare disabled. 1 = src data is used for color compare, perform write operation if colors match. 2 = dst data is used for color compare, perform write operation if colors match. 3 = reserved 4 = reserved 5 = src data is used for color compare, perform write operation if colors don? match. 6 = dst data is used for color compare, perform write operation if colors don? match. 7 = reserved
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-23 this register speci?s the current rasterop, alpha, and other parameters for the drawing engine data path. this register must be properly initialized for blts, alpha blends, and vectors. this register is unchanged by any drawing operations. this register is used to load the source xy address for a blt operation. 15:13 reserved 12 sp r/w 0 the sp ?ld indicates if the pattern is a solid color. sp is bit 12 of this register. legal values are: 0 = patterns are handled normally. 1 = the value held in the monopatfcolor foreground color register will be used as pattern data. 11 reserved 10:8 src[2:0] r/w 0 the src[2:0] ?ld is a 3-bit parameter specifying how the source data are created. src[2:0] are in bits 11:8 of this register: 0 = src data is color data from sgram. this is used for screen-to- screen blts with either rops or alpha blends. 1 = src data is color bitmap data from the host processor. this is used for host-to-screen blts with either rops or alpha blends. 2 = src data is pc mono bitmap data from the host processor. this is used for color expanding host-to-screen blts. this encoding implies that host data is padded to a dword boundary at the end of scanlines. 3 = src data is pc mono font data from the host processor. this is used for text rendering. this encoding implies highly packed host data and forces the drawing engine to use srcstride=bltsize. width and srclinear=0. 4 = src data is 4-bit alpha values from the host. this option is used with alpha-blending. 5 = src data is 8-bit alpha values from the host. this option is used with alpha-blending. 6 = use only surface values for alpha-blending, no src data present. 7 = reserved 7:0 rop[7:0] r/w 0 this ?ld is an 8-bit parameter that speci?s the rasterop. it is the same format used by gdi. rop[7:0] are in bits 7:0 of this register. table 20: blt control bit symbol acces s value description table 21: source address, xy coordinates bit symbol acces s value description offset 0x04 f42c source address, xy coordinates 31:27 reserved 26:24 y[10:8] r/w 0 unsigned 11-bit y source address 23:16 y[7:0] r/w 0 15:11 reserved 10:8 x[10:8] r/w 0 unsigned 11-bit x source address 7:0 x[7:0] r/w 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-24 the x and y ?lds are unsigned 11 bit numbers allowing a 2k by 2k address space. since the drawing engine uses linear addresses internally, the x and y coordinates in this register will be converted to a linear address. it is byte accessible; a write to the high byte of this register begins the conversion process from xy to linear. it is not used for vectors. note that srclinear should be utilized when using monochrome bitmaps or text. the lower six bits of srclinear specify the starting bit position within a dword . also loads the srclinear register with the converted xy address. this register is used to load the starting xy pixel destination coordinate for a drawing operation. the x and y ?lds are unsigned 11-bit numbers allowing a 2k by 2k address space. since the drawing engine uses linear addresses internally, the x and y coordinates in this register will be converted to a linear address. it is byte accessible; a write to the high byte of this register begins the conversion process from xy to linear. this register causes the same behavior as writing to dstxy2, which is provided to allow for command register bursting during vector commands. drawing commands that require patterns must use this register to specify the destination coordinate. using the dstlinear register to specify destination during a pattern command will cause errant results. also loads the dstlinear register with the converted xy address.this register speci?s the height and width of a blt operation in pixels/scanlines. table 22: destination address, xy coordinates bit symbol acces s value description offset 0x04 f430 destination address, xy coordinates 31:27 reserved 26:24 y[10:8] r/w 0 unsigned 11-bit y destination address 23:16 y[7:0] r/w 0 15:11 reserved 10:8 x[10:8] r/w 0 unsigned 11-bit x destination address 7:0 x[7:0] r/w 0 table 23: blt size bit symbol acces s value description offset 0x04 f434 blt size 31:28 reserved 27:16 h r/w fff height of the blt in scanlines 15:12 reserved 11:0 w r/w fff width of the blt in pixels
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-25 w[11:0] speci?s the width of a blt in pixels. the minimum allowed value is 1 and the maximum value is 4k-1. zero is not a valid value for this ?ld. w[11:0] corresponds to bits 11:0 of this register. h[11:0] speci?s the height of a blt in lines. the minimum allowed value is 1 and the maximum value is 4k-1. zero is not a valid value for this ?ld. h[11:0] corresponds to bits 27:16 of this register. note that loading the high byte of this register starts a blt or alpha blending operation. this register is unchanged by any drawing operations. this register is used to load the starting xy pixel destination coordinate for a drawing operation. the x and y ?lds are unsigned 11-bit numbers allowing a 2k by 2k address space. since the drawing engine uses linear addresses internally, the x and y coordinates in this register will be converted to a linear address. it is byte accessible; a write to the high byte of this register begins the conversion process from xy to linear. this register causes the same behavior as writing to dstxy, which is provided to allow for command register bursting during bitblt commands. drawing commands that require the use of patterns must use this register to specify the destination coordinate. using the dstlinear register to specify the destination during a pattern command will cause errant results. also loads the dstlinear register with the converted xy address. this register holds the two error term values for the bresenham line algorithm. these values are computed by the host processor as follows: const0 = 2 x dmin - 2 x dmax table 24: destination address, xy2 coordinates bit symbol acces s value description offset 0x04 f438 destination address, xy2 coordinates 31:27 reserved 26:24 y[10:8] r/w 0 unsigned 11-bit y destination address 23:16 y[7:0] r/w 0 15:11 reserved 10:8 x[10:8] r/w 0 unsigned 11-bit x destination address 7:0 x[7:0] r/w 0 table 25: vector constant bit symbol acces s value description offset 0x04 f43c vector constant 31:24 const1 [15:8] r/w 0 const1 = 2 x dmin 23:16 const1 [7:0] r/w 0 15:8 const0 [15:8] r/w 0 const0 = 2 x dmin - 2 x dmax 7:0 const0 [7:0] r/w 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-26 const1 = 2 x dmin this register is unchanged after the vector is completed. this register holds the vector length, drawing octant, and the initial error value for the bresenham line algorithm. the initial value of the error term is held in bits 31:16 and is computed by the host processor: initerr = 2 x dmin - dmax len = dmax + 1 where dmin = min (dx,dy), dmax = max(dx,dy) the last pixel can be left undrawn by simply decrementing the len parameter prior to loading. note: loading the high byte of this register starts the vector drawing engine. a len value of 0 is illegal and should be avoided. this register is unchanged after the vector is completed, but you need to reload it to start the next vector anyway. table 26: vector count control bit symbol acces s value description offset 0x04 f440 vector count control 31:24 initerr[15:8] r/w 0 initial error value for the bresenham line algorithm 23:16 initerr[7:0] r/w 0 15:8 oct, len[11:8] r/w 0 bits 15:13 specify the drawing octant as follows: bit 15 1 = y is major axis 0 = x is major axis bit 14 1 = negative x step 0 = positive x step bit 13 1 = negative y step 0 = positive y step 7:0 len[7:0] r/w 0 length of the major axis in pixels table 27: transmask bit symbol acces s value description offset 0x04 f444 transmask 31:24 tmask[31:24] r/w ni transparency mask used in the color compare 23:16 tmask[23:16] r/w ni 15:8 tmask[15:8] r/w ni 7:0 tmask[7:0] r/w ni
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-27 this register holds the transparency mask used in the color compare. it should be initialized prior to any blt that enables color compare. the appropriate number of bytes need to be loaded in accordance with the current color depth. thus, if the current depth is 8 bits, only the lowest byte need be written. if the depth is 15 or 16 bits, the lowest two bytes need to be written. in 32-bit mode, all bytes should be written. setting a bit to 1 in this register enables the corresponding bit within a pixel to be used in the color compare. clearing a bit to 0 in this register excludes the corresponding bit within a pixel from being used in the color compare. this effectively causes that bit(s) to be considered a match in the color compare. correct programming values are shown below: 08bpp: 0x000000ff // all 8 bits included in color compare 15bpp: 0x00007fff // 15 lower bits included in color compare 16bpp: 0x0000ffff // all 16 bits included in color compare 32bpp: 0x00ffffff // 24 lower bits included in color compare when reading the value of this register, the lower byte will be replicated into all four byte lanes in 8-bpp mode. in 15 or 16-bpp mode, the lower word will be replicated into the upper word. in 32-bit mode, all bits are unique and will read back the 32-bit data that was written. this register is unchanged by drawing operations. this register speci?s the foreground color for monochrome pattern expansion, lines, and solid ?ls. the appropriate number of bytes need to be loaded in accordance with the current color depth. thus, if the current depth is 8 bits, only the lowest byte need be written. if the depth is 16 bits, the lowest two bytes need to be written. when reading the value of this register, the lower byte will be replicated into all four byte lanes in 8-bpp mode. in 16-bpp mode, the lower word will be replicated into the upper word. in 32-bit mode, all bits are unique and will read back the 32-bit data that was written. this register is unchanged by drawing operations. table 28: monopatfcolor bit symbol acces s value description offset 0x04 f5f8 monopatfcolor 31:0 monopatfcolor[31:0] r/w ni speci?s the foreground color for monochrome pattern expansion, lines, and solid ?ls. table 29: monopatbcolor bit symbol acces s value description offset 0x04 f5fc monopatbcolor 31:0 monopatbcolor[31:0] r/w ni holds the background color monochrome pattern expansion, lines, and solid ?ls.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-28 this register holds the background color for monochrome pattern expansion, lines, and solid ?ls. the appropriate number of bytes need to be loaded in accordance with the current color depth. thus, if the current depth is 8 bits, only the lowest byte need be written. if the depth is 16 bits, the lowest two bytes need to be written. when reading the value of this register, the lower byte will be replicated into all four byte lanes in 8-bpp mode. in 16-bpp mode, the lower word will be replicated into the upper word. in 32-bit mode, all bits are unique and will read back the 32-bit data that was written. this register is unchanged by drawing operations. this read-only register returns the drawing engine status. writes to this register have no effect but do not hang the bus. table 30: enginestatus bit symbol acces s value description drawing engine real time registers offset 0x04 f800 enginestatus 31:11 reserved 10 irq r 0 draw engine interrupt request status 1 = a 2d interrupt is being requested. this re?cts the actual state of the irq signal leaving the drawing engine. 9 dedone r 1 dedone and debusy are the primary drawing engine activity indicators.they are the complement of each other. when debusy is logic 1 (dedone a 0), the drawing engine is active. if enginecon? bit 9 is a 1, ?ctive?is de?ed as: processing a register access emptying commands or data from the host fifo performing an operation such as a bitblt or bitblt line waiting for a memory transaction to complete if enginecon? bit 9 is a 0, the engine is active when a blt/vector starts and becomes inactive when the blt/vector ?ishes. all memory writes are complete, and the host fifo is empty. debusy is read as logic 0, the drawing engine is guaranteed to be idle. 8 debusy r 0 7:4 reserved 3 hfifo_not empty r 0 host fifo is not empty. 2 hfifo_full r 0 host fifo is full. blt is busy; another blt is pending in shadow registers. 1 vector active r 0 vector is in process. 0 blt active r 0 blt is in process.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-29 this register is currently used to reset the state machines in the drawing engine. it does not reset any other registers in the engine. table 31: paniccontrol bit symbol acces s value description offset 0x04 f804 paniccontrol 31:8 reserved 7:0 rst w - used to reset the state machines in the drawing engine. writing 0x0000_0001 to this register will halt the drawing engine and place it in an idle state. writing 0x0000_0000 will allow the de to be reprogrammed and resume normal operation. it may be necessary for software to implement a delay between setting the rst signal to 1 and resetting it to 0. table 32: enginecon? bit symbol acces s value description offset 0x04 f808 enginecon? 31:11 reserved 10 irq_clr r/w 0 irq_clr (bit 10) is a self-clearing bit used to reset drawing engine irq ?p-?p. the irq ?p-?p is set when the debusy bit in the enginestatus register transitions from 1 to 0. it is cleared under software control by setting irq_clr to 1. see bmode for a description of debusy. 9 bmode r/w 0 bmode selects between two slightly different behaviors of debusy and dedone (enginestatus register). 0=the debusy bit is set to 1 when the blt/vector state machine becomes active i.e., a drawing operation is starting. the bit is cleared only when the state machine is idle, all memory writes are completed, and the command fifo is empty. 1=the debusy bit is set whenever the blt/vector state machine is active or the command fifo is not empty. the debusy bit will be cleared when the engine is idle and the command fifo is empty. note that in this mode, the draw engine will go busy whenever a register is loaded. using interrupts can be tricky in this mode. 8 irq_en r/w 0 irq_en (bit 8) is used to enable the interrupt signal leaving the drawing engine module. when irq_en is set to a 1, the interrupt signal is enabled. when set to 0, the interrupt signal leaving the drawing engine is masked. the irq_en does not affect the actual irq ?p-?p. it merely masks the irq bit leaving the module. 7:3 reserved
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-30 this register is used to con?ure speci? drawing engine features and to enable the interrupt request signal. bsi (bit 1) and bsm (bit 2) toggle byte and word swapping. certain registers which contain byte- or word-oriented data but which must be manipulated as dwords need to be byte- or word-swapped when written on big-endian architectures. these include hostdata, patrammono and patramcolor. the drawing engine automatically determines whether swapping is necessary based on the global ?ndian??g. the bottom byte of this register should not be altered while drawing commands are in progress. this register is used to provide software with a method of determining the number of available entries in the host fifo. there are 32 fifo locations in the host fifo. if this register is read as 0, it indicates there are no available fifo locations available for writing. a write to the host fifo while the fifo is full (or almost full) will result in wait states on the pi bus. if this register is read as 0x20, it indicates that all 32 entries are available for writing. a software driver can read this register and subsequently write the corresponding number of dword s of data to the host fifo. this will prevent the pnx15xx series from generating pci retries since a write will not occur when the host fifo is full. 2 bsm r/w 0 bsi (bit 1) and bsm (bit 2) toggle byte and word swapping. setting bsi to 1 reverses the sense of the global endian bit for data read from the host data input port, so that data are swapped when written when they normally would not be, and vice versa. this bit affects host blt data, pattern loading. it is intended for debugging and should be set to 0 for normal operation. 1 bsi r/w 0 bsi (bit 1) and bsm (bit 2) toggle byte and word swapping. setting bsm to 1 reverses the sense of the global endian bit for data being read and written to the memory port. it is intended for debugging and should be set to 0 for normal operation. 0 reserved table 32: enginecon? bit symbol acces s value description table 33: hostfifostatus bit symbol acces s value description offset 0x04 f80c hostfifostatus 31:6 reserved 5:0 level[5:0] r 0x20 used to provide software with a method of determining the number of available entries in the host fifo.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-31 this register is used to provide software with the module type, revision, and aperture size. drawing engine data registers table 34: powerdown bit symbol acces s value description offset 0x04 fff4 powerdown 31 power_down r/w 0 powerdown register for the module 0 = normal operation of the peripheral. this is the reset value. 1 = module is powered down and module clock can be removed. at powerdown, module responds to all reads with deadabba (except for reads of powerdown bit) and all writes with err ack (except for writes to powerdown bit). 30:0 unused - ignore during writes and read as zeroes. table 35: module id bit symbol acces s value description offset 0x04 fffc module id 31:16 moduleid r 0x0117 moduleid 15:12 majrev r 0x2 major revision 11:8 minrev r 0x0 minor revision 7:0 size r 0x10 mmio aperture size is 68 kb. table 36: drawing engine data registers bit symbol acces s value description offset 0x04 f600?6ff patrammono this address range allows write-only access to the pattern ram. it is used to load monochrome patterns into the pattern cache with automatic color expansion. each bit in this address range represents one pixel in the pattern cache. a ? written here is converted to the foreground color and written to the pattern ram. a ??written here is converted to the background color and written to the pattern ram. a monochrome pattern always consists of 64 bits of data regardless of the pixel color depth. the amount of color expanded data, however, is dependent on color depth. the monochrome data should be written to the address range 0x1600 - 0x1607. note that patterns must be loaded sequentially because the lower order address bits are ignored as a pattern is loaded.
philips semiconductors pnx15xx series volume 1 of 1 chapter 20: 2d drawing engine 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 20-32 offset 0x04 f700?7ff patramcolor (256 bytes) this address range allows write access to the pattern cache ram. it is only for full color patterns. a full color pattern consists of 64 bytes of data at 8 bpp, 128 bytes at 16 bpp, and 256 bytes of data at 32 bpp. full color patterns should be loaded starting at address 0x1700. patterns must be loaded sequentially because the lower order address bits are ignored as a pattern is loaded. offset 0x05 0000 ffff host data (64 kb - memory space) this address space receives host data for blts that require host data. all addresses in this range map to the host write buffer. it allows the host to use rep movsd instructions to ef?iently copy data from system memory to the blt engine. when doing a blt that requires host data (host to screen), it is necessary to program src[1:0] in the bltctl register to select host data. this register is byte accessible, but... host-to-screen blts always require an integer number of dword s to be transferred from the host. although the hostdata port will accept byte writes to load individual bytes of data, writing the high byte actually transfers the host data into the engine. reads from this register return unknown data but do not hang the bus. writing excess data to this register space is not recommended, but will not cause the bus to hang. table 36: drawing engine data registers bit symbol acces s value description
1. introduction the mpeg-2 variable length decoder (vld) consists of two write dma channels that write back data to main memory; one for run length (rl) data and one for macro block header (mbh) data. the vld decodes the huffman encoded mpeg-1 and mpeg-2 (main pro?e and main level) video elementary bitstreams. the vld unit, enabled by the cpu, operates independently during the slice-level decoding. the remaining bitstream decoding is carried out by the trimedia (tm3260) cpus and appropriate software. the vld also assists the cpu and outputs a stream of macroblock headers and a stream of run- level pairs. run-level pair expansion, produced by the vld into actual quantized dct values and their subsequent rearrangement into a natural order, is carried out by the tm3260. the tm3260 cpus are also responsible for restoring or ?equantizing the quantized dct values by multiplying them by the corresponding values in the 8x8 dct quantization matrix. the tm3260 optionally performs the frequency domain ?tering in association with the half-resolution mode, and perform the inverse discrete cosine transformation on each of the 8x8 dequantized blocks. the tm3260 cpu reconstructs the ?al video samples from the macroblock header data decoded by the vld, the reference frame data stored in main memory, and the differential data previously computed. 1.1 features after initialization, the tm3260 cpu controls the vld through its command register. there are currently nine commands supported by the vld: shift the bitstream by some number of bits. parse a given number of macroblocks, one row, or parse continuously without stopping at the slice header. search for the next start code. reset the variable length decoder. initialize the vld. search for the given start code. chapter 21: mpeg-1 and mpeg-2 variable length decoder pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-2 flush vld output buffers.
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-3 2. functional description 2.1 vld block level diagram 3. operation 3.1 reset-related issues a system reset will cause the variable length decoder to clear all registers to default values and will force all state machines to the idle state. any dma activity in figure 1: vld block diagram mmio-dtl interface control and status registers input dma fifo writeback run length fifo writeback mb header fifo dtl - dma mtl interface shifter mb_addr mb_type cbp dmv and motion dct_lum dct_chr dctcoef[0] dctcoef[1] escape_codes start_code_detector vld state machines vld_int dcs network dtl0 dtl1 dtl2
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-4 progress will be aborted. the ?eset the variable length decoder?command section 3.2.9 on page 21- 7 or soft reset is controlled by the hardware so that any dma activity that is in progress will complete before the soft reset has a complete effect. software should wait for the ?ld command done status bit to be set before proceeding with the next command. remark: the vld_inp_cnt is cleared after reset. however, this is not treated as a dma_input_done condition in the vld and the cpu will not be interrupted by the vld after reset with a dma_input_done condition. the mpeg video bitstream buffer should be refilled as needed and the vld_inp_cnt rewritten with a proper value before issuing new commands to the vld after reset. 3.2 vld mmio registers 3.2.1 vld status (vld_mc_status) the vld_mc_status register contains current status information which is most pertinent to the normal operation of an mpeg video decode application. writing a logic ??to any of the status bits other than bit-0 clears the corresponding bit. writing a logic ? has no effect. exception: bit 0 (command done) is cleared only by issuing a new command. writing a logic ??to bit zero of the status register will result in unde?ed behavior of the vld . note that several status bits may be asserted simultaneously. t ab le 2 lists the function of each status ?ld. table 1: software reset procedure cycle no. action remarks i the cpu issues the ?eset the variable length decoder command by writing the corresponding command code into the vld_command register. i to j the vld will complete any dma transactions that are already in progress. any new dma transactions will be aborted. the vld then raises the vld_ready_to_reset signal. any dma transactions, once started, will not be aborted in the middle. k if (vld_ready_to_reset) then the vld interrupts the cpu. assumes k>j; otherwise it is jth cycle. the full reset clears all internal buffers, state machines, and leaves the following registers with the value of 0x0: vld_command vld_ctl vld_bit_cnt vld_inp_cnt vld_mbh_cnt vld_rl_cnt the vld_status register contains the value 0x0000_0001.
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-5 when an error occurs in the vld, the corresponding error ?g (bitstream error or rl over?w error) is set and an interrupt is generated if corresponding bits in the vld_ie register is set. refer to section section 3.4 for details on the error handling mechanism. 3.2.2 vld interrupt enable (vld_ie) this vld_ie read/write register allows the cpu to control the initiation of the interrupt for the corresponding bits in the vld_mc_status register. writing a one to any of these bits in the vld_ie register enables the interrupt for the corresponding bit in the status register. 3.2.3 vld control (vld_ctl) when vld detects a new slice start code in the bit-stream, it writes the lower 8-bits of the start code into the slice_start_code ?ld of the vld_ctl register before interrupting the cpu. when re-started, the vld reads the slice_start_code from the vld_ctl register and writes this value into bits 16-23 of the last word in the ?st mb_header and sets the mb_?st bit to 1. to allow the cpu to switch bitstream at the slice level, cpu can write the desired slice start code and slice_start_code_strobe in the vld control register. the value of ? in the slice_start_code_strobe will cause the vld to update the slice_start_code ?ld with the given slice_start_code value. the other ?lds in the vld_ctl register are not updated when the input data contains a value of ??in the slice_start_code_strobe ?ld. the slice_start_code_strobe bit is always read as 0. the cpu must write the slice_start_code only when the vld is not active. in order to update the dma_input_done_mode ?lds, the slice_start_code_strobe bit value must be set to ?? the use of the dma_input_done_mode bit is described in t ab le 3 . table 2: vld status name size (bits) description vld command done 1 logic ? indicates successful completion of current command. this bit is cleared by issuing a new command. start code detected 1 logic ??indicates vld encountered 0x000001 while executing current command. this bit is cleared by writing a logic ??to it. bitstream error 1 logic ??indicates vld encountered an illegal huffman code or an unexpected start code. refer to section 3.4 error handling for details on the error handling procedure. this bit is cleared by writing a logic ??to it. dma input done 1 conditions for setting this bit depends on the value of the dma_input_done ?ld in the vld_ctl register. refer to section 3 vld control and section 3.3 vld oper ation for details. this bit is cleared by writing a logic ??to it. dma macroblock header output done 1 logic ??indicates that the macroblock header dma write transfer has completed. dma run/level output done 1 logic ??indicates that the run/level dma write transfer has completed. rl over?w error 1 logic ??indicates over?w of run/level values within a block. refer to section 3.4 for details on the error handling procedure. this bit is cleared by writing a logic ??to it.
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-6 3.2.4 vld dma current read address (vld_inp_adr) and read count (vld_inp_cnt) the cpu writes the main memory buffer address from which bitstream to be read by vld in vld_inp_adr register. the number of bytes to be read by the vld is updated by the cpu in the vld_inp_cnt register. the vld unit uses two 64-byte buffers to store the input bitstream. the vld reads the bitstream data from the main memory and updates the vld_inp_adr and the vld_inp_cnt register. the content of the vld_inp_adr register re?cts the next or the current fetch address of the bitstream data. the vld interrupts the cpu when it has consumed all the given bitstream data in the main memory (the dma_input_done condition). the value of the dma_input_done_mode bit in the vld_ctl register is used to select the condition for raising the dma_input_done ?g. refer to t ab le 3 for more details. the vld input address is word (32-bit) aligned and the count value in number of bytes is also word aligned. 3.2.5 vld dma macroblock header current write address (vld_mbh_adr) the cpu writes the main memory macroblock header buffer address in the vld_mbh_adr register in order to output the macroblock header data in main memory. the vld updates this address whenever data is transferred to main memory via the dma logic. the address always represents the next write address of the macroblock header data. this register must be 32-bit aligned. 3.2.6 vld dma macroblock header current write count the cpu writes the main memory macroblock header buffer size formatted as the number of 8-byte words into the vld_mbh_cnt register in order to output the macroblock header data in main memory. the vld updates the buffer size whenever data is transferred to main memory via the dma logic. the buffer size always represents the remaining empty buffer space. note that in mpeg-2 when macroblock headers are written to main memory, they are written in groups of six 4-byte vectors (24 bytes). table 3: vld control name size (bits) description dma_input_done_mode 1 when this bit is ?? vld sets the dma_input_done ?g (in vld_mc_status register) when the dma_inp_cnt transitions from non-zero to zero. when this bit is ?? the same ?g is set only with the additional condition that both dma input buffers are empty. the slice_start_code_strobe bit ?ld must be set to ? in order to update this ?ld. slice_start_code 8 slice start code when the vld is restarted; the slice_start_code_strobe bit ?ld must be set to ??in order to update this ?ld. slice_start_code_strobe 1 when cpu writes 1 into this ?ld, vld copies the value of slice_start_code into its internal register. cpu should do this only when the vld is stopped. this bit is always read as 0.
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-7 3.2.7 vld dma run-level current write address (vld_rl_adr) the cpu writes the main memory run-level pair buffer address in the vld_rl_adr register in order to output the run-level pairs in main memory. the vld updates this address whenever data is transferred to main memory via the dma logic. the address always represents the next write address of the macroblock header data. the buffer address must be 32-bit aligned. 3.2.8 vld dma run-level current write count the cpu writes the main memory run-level pairs buffer size formatted as the number of words into the vld_rl_cnt register in order to output the run-level pairs data in main memory. the vld updates the buffer size whenever data is transferred to main memory via the dma logic. the buffer size always represents the remaining empty buffer space. 3.2.9 vld command (vld_command) this read/write register indicates the next action to be taken by the vld. a command is sent to the vld by writing the corresponding 4-bit command code in the command ?ld of the vld_command register. some commands require an associated count value which resides in the least signi?ant 8 bits of this register. the following nine vld commands are currently available: shift the video bitstream by ?ount?bits (where ?ount?is given in the count ?ld of the register and must be between 0 and 15 inclusive). parse ?ount?macroblocks (where ?ount?is given in the count ?ld of the register and must be between 0 and 255 inclusive). search for the next start code. reset the variable length decoder. initialize the vld (to clear the vld_bit_cnt register). search for the speci? 8-bit start code pattern given in the count ?ld of the register. flush the vld output buffers to main memory. parse one row of macroblocks. parse macroblocks continuously. (count ?ld is unused, but cannot be programmed to 0.)
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-8 the cpu must wait for the vld to halt before the next command can be issued. note that there are several ways in which a command may complete. only a successful completion is indicated by the command done bit in the status register. a command may complete unsuccessfully if a start code or an error is encountered before the table 4: vld commands code command flags set (after completion of the command) description 0x1 shift the bitstream by ?ount?bits command done vld shifts the number of bits in its internal shift register. the shift register value is available in the vld_sr register. the ?g is reset by issuing the new command. 0x2 parse for a given number of macroblocks command done and/or start code detected vld parses for a given number of macroblocks; however, if vld encounters a start code, the parsing action will be terminated and vld sets only the start code detected ?g. if vld parses the given number of macroblocks without encountering a start code, vld will set the command done ?g. the start code detected ?g is reset by writing a ??value to the ?g. the command done ?g is reset by issuing the new command 0x3 search for the next start code start code detected and command done vld search for a start code. the search code has 0x000001 pre? and additional 8-bit value; a 32-bit value with 0x000001 pre?. the start code detected ?g is reset by writing a ??value to the ?g. the command done ?g is reset by issuing the new command 0x4 reset the variable length decoder command done refer to section 3.4 error handling . 0x5 initialize the vld none the bit count register is initialized to zero. the initialization action is immediate without any delay. 0x6 search for the given start code start code detected and command done vld search for a start code with a given 8-bit lsb of the 32-bit start code. the search code has 0x000001 pre? and the additional 8-bit value is given in the ?ount??ld of the vld_command register. the start code detected ?g is reset by writing a ??value to the ?g. the command done ?g is reset by issuing the new command 0x7 parse one row of macroblocks start code detected this command instructs the vld to parse one complete row of macroblocks. if the row contains more than one slice, vld parses the intermediate slice headers without cpu intervention, provided these slice headers have a 0 bit after the 5-bit quantizer_scale_code. if the vld encounters a start code different from the start code of the current slice, or if the slice header has a 1 bit after the quantizer_scale_code, it sets the start-code-detected ?g and ends the operation. warning: the ?ount??ld of the vld_command register is still in effect as in the ?arse a number of macroblocks?command: vld stops and sets the command-done ?g after ?ount?macroblock headers are parsed. ?ount?must be set to at least mb_width (number of macroblocks per row in the picture) to guarantee the entire row is parsed before the vld stops. 0x8 flush write fifos command done the vld ?shed the remaining macroblock header data and the remaining run-level data to the main memory. 0x9 parse long command done this command instructs the vld to parse and to continue as long as the next start code id is for the next slice. any other start code id will cause the vld to stop and interrupt with the ?ommand done?status bit set. note the count ?ld cannot be programmed to 0.
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-9 requested number of items have been processed. note also that the expiration of a dma count does not constitute the completion of a command. when a dma count expires the vld is stalled as it waits for a new dma to be initiated. it is not halted. the ?nitialize vld?command initializes the vld_bit_cnt register (the bit counter) to zero. the ?earch for the given start code?command searches for the start code pattern given in the count ?ld (in the least signi?ant 8 bits) of the vld_command register. a valid mpeg-1/-2 start code is a 32-bit pattern with the upper 24-bits equal to 0x000001. for each start code encountered in the bitstream, the 8-bits following the 0x000001 pattern is compared against the given 8-bit start code pattern until a perfect match is obtained. once the given start-code is found, the vld sets the command_done bit in the vld_mc_status register. at that point, the vld will interrupt the cpu if the corresponding bit in the vld_ie register is also set. 3.2.10 vld shift register (vld_sr) this read only register is a shadow of the vlds operational shift register and it allows the cpu to access the bitstream through the vld. bits 0 through 15 are the current contents of the vld shift register. bit 16 to 31 are reserved and should be treated as unde?ed by the programmer. 3.2.11 vld quantizer scale (vld_qs) this 5-bit register read/write register contains the quantization scale code to be output by the vld until it is overridden by a macroblock quantizer scale code. the quantizer scale code is part of the macroblock header output. 3.2.12 vld picture info (vld_pi) this 32-bit read/write register contains the picture layer information necessary for the vld (and mc) to parse the macroblocks within that picture. again, the values of each of these ?lds are determined by the appropriate standard (mpeg-1 or mpeg-2) 3.2.13 vld bit count (vld_bit_cnt) the number of bits consumed by the vld is updated in the vld_bit_cnt register. vld_bit_cnt can be initialized to zero by issuing the ?nitialize vld?command. it counts upward when bits are shifted out and consumed by the vld. this counter wraps around after reaching the maximum value. 3.3 vld operation the normal mode of operation will be for the cpu to request the vld to parse some number of macroblocks. once the vld has begun parsing macroblocks it may stop for any one of the following reasons: table 5: vld command register name size (bits) description count 8 for the ?hift bitstream command, only the lower 4 bits are used; the upper 4 bits should be set to 0. all 8 bits are used for the ?arse macroblocks?and ?earch for given start code?commands. command 4 command code of the vld command to be executed
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-10 the command was completed with no exceptions. a start code was detected. an error was encountered in the bitstream. the vld input dma completed and the vld is stalled waiting for more data. one of the output dma for rl or hdr processing has been completed. under normal circumstances, the cpu is interrupted whenever the vld halts. consider the case in which the vld has encountered a start code. at this point, the vld will halt and set the status ?g which indicates that a start code has been detected. this ?g will generate an interrupt to the cpu. upon entering the interrupt service routine, the cpu will read the vld status register to determine the source of the interrupt. once it has been determined that a start code has been encountered, the cpu will read 8 bits from the vld shift register to determine the type of start code that has been encountered. if a slice start code has been encountered, the cpu will read from the shift register the slice quantization scale code and any extra slice information (from the slice header). the slice quantization scale code will then be written back to the vld_qs register. before exiting the interrupt service routine, the cpu will clear the start code detected status bit in the status register and issue a new command to process the remaining macroblocks. 3.3.1 vld input the vld reads the video bitstream from the main memory and performs the variable length decoding process. the cpu writes the main memory buffer address from which bitstream to be read by vld in vld_inp_adr register. the number of bytes to be read by the vld is updated by the cpu in the vld_inp_cnt register. the vld unit uses two 64-byte buffers to store the input bitstream. the vld reads the bitstream data from the main memory and updates the vld_inp_adr and the vld_inp_cnt register. the content of the vld_inp_adr register re?cts the next fetch address of the bitstream data. the content of the vld_inp_cnt register re?cts the number of bytes to be read from the main memory. when the number of bytes to be read from the main memory transitions from non-zero to zero, the dma_input_done ?g in the vld_mc_status is set. an interrupt will be sent to the cpu also if the corresponding interrupt enable bit in the vld_ie register is set. the cpu should then provide the new bitstream buffer address and the number of bytes in the bitstream buffer to the vld. the vld unit also updates a bit counter in the vld_bit_cnt register to keep track of the number of bits consumed in the decoding process. the bit counter is updated only after a successful decoding of a symbol. the cpu can read this bit counter from the vld_bit_cnt register. this register can be initialized to zero by sending the ?nitialize vld?command. 3.3.2 vld output the output of the vld are always transferred back to main memory for down stream software mpeg blocks. all vld output are transferred via dma to separate main memory areas for mb headers and run-level encoded dct coef?ients.
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-11 mpeg-2 parsing for each mpeg-2 macroblock parsed by the vld, six 32 bit words of macroblock header information will be output from the vld. see figure 2 . the ?lds described in figure 2 may or may not be valid depending upon the mpeg- 2 video standard. see t ab le 6 for more details on the macroblock header data. figure 2: mpeg-2 macro block header output format esc count mba inc mb type mot type dct type mv count mv format dmv mv field sel [0][0] motion code [0][0][1] motion residual [0][0][0] motion residual [0][0][1] motion code [0][0][0] mv field sel [1][0] motion code [1][0][1] motion residual [1][0][0] motion residual [1][0][1] motion code [1][0][0] mv field sel [0][1] motion code [0][1][1] motion residual [0][1][0] motion residual [0][1][1] motion code [0][1][0] mv field sel [1][1] motion code [1]1][1] motion residual [1][1][0] motion residual [1][1][1] motion code [1][1][0] quant scale cbp dmvector[0] dmvector[1] 31 first forward motion vector second forward motion vector (for mpeg-2 only) first backward motion vector second backward motion vector (for mpeg-2 only) 0 1 2 3 4 6 11 17 25 7 15 23 29 30 31 13 7 15 23 29 30 31 13 7 15 23 29 30 31 13 7 15 23 29 30 31 13 4 10 12 14 31 w1 w2 w3 w4 w5 w0 mb2 first mb slice_start_code 23 16 mb1 table 6: references for the mpeg-2 macroblock header data item default value references from mpeg-2 video standard, is 13818-2 document esc count 0 section 6.2.5 mba inc - section 6.2.5 and table b-1 mb type unde?ed section 6.2.5.1 and tables b-2, b-3, and b-4; only 5 msb bits from the tables are used mottype unde?ed section 6.2.5.1; field or frame motion type will be decided by the user dct type unde?ed section 6.2.5.1 mv count unde?ed tables 6-17 and 6-18. the mv count value is one less than the value from the tables. mv format unde?ed tables 6-17 and 6-18 first mb 0 set to ??for the ?st macroblock of a slice dmv unde?ed tables 6-17 and 6-17
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-12 mpeg-1 parsing for each mpeg-1 macroblock parsed by the vld, four 32-bit words of macroblock header information will be output from the vld. refer to figure 1 . the ?lds described in figure 3 may or may not be valid depending upon the mpeg- 1 video standard. see t ab le 7 for more details on the macroblock header data mv field sel[0]0] to mv field sel[1][1] unde?ed section 6.2.5 and 6.2.5.2 motion code[0][0][0] to motion code[1][1][1] unde?ed section 6.2.5.2.1 and table b-10 motion residual[0][0][0] to motion residual[1][1][1] unde?ed section 6.2.5.2.1; the corresponding rsize bits are extracted from the bitstream and stored as left justi?d; to get the ?al value shift the given number by (8 - corresponding rsize). the rsize values are stored in mp_vld_pi register start code - copy of the internal start-code register; see section 5. register descr iptions . dmvector[1] and dmvector[0] unde?ed section 6.2.5.2.1 and table b-11; signed 2-bit integer from table b11. cbp - section 6.2.5, 6.2.5.3 and table b-9 quant scale - section 6.2.5; 5 bits from bitstream; use table 7-6 to compute the quant scale value. table 6: references for the mpeg-2 macroblock header data ?ontinued item default value references from mpeg-2 video standard, is 13818-2 document figure 3: mpeg-1 macro block header output format esc count mba inc mb type motion code [0][0][1] motion residual [0][0][0] motion residual [0][0][1] motion code [0][0][0] motion code [0][1][1] motion residual [0][1][0] motion residual [0][1][1] motion code [0][1][0] quant scale cbp 31 first forward motion vector first backward motion vector 0 1 2 3 4 6 11 17 25 7 15 23 29 30 31 13 7 15 23 29 30 31 13 4 10 12 14 31 w1 w2 w3 w0 mb1 mb2 first mb slice_start_code 23 16 shaded areas represent bits not implemented in the mpeg-1 specification. these bits are written as zeros.
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-13 the dct coef?ients associated with the macroblock are output to a separate memory area. each dct coef?ient is represented as one 32 bit quantity (16 bits of run and 16 bits of level). for intra blocks, the dc term is expressed as 16 bits of dc size and a 16 bit value whose most signi?ant bits (the number of bits used for dc level is determined by dc size) represent the dc level. each block of dct coef?ients is terminated by a run value of 0xff. run-level output data the dct coef?ients associated with the macroblock are output to a separate memory area and each dct coef?ient is represented as one 32-bit quantity (16 bits of run and 16 bits of level). for intra blocks, the dc term is expressed as 16 bits of size and a 16-bit value whose most signi?ant bits represent the dc level. the number of bits used for dc level is determined by the dc size)? each block of dct coef?ients is terminated by a run value of 0xff. 3.3.3 restart the vld parsing the restart of the parsing command at the last decoded symbol position is done through the use of the vld_bit_cnt register to count the number of bits from the main memory vld buffer that have been consumed. the vld_bit_cnt register can be initialized to zero by issuing the vld_init command. it counts up when bits are shifted out of the vld. this counter wraps around after reaching its maximum value. 3.4 error handling the vld can generate two types of errors. the vld_mc_status register has two vld error ?gs.the vld errors are 1) bitstream parsing error and 2) run-level over?w error. see t ab le 8 for details on the vld error handling procedure. table 7: references for the mpeg-1 macroblock header data item default value references from is 11172-2 document esc count 0 section 2.4.3.6 mba inc - section 2.4.3.6 mb type unde?ed section 2.4.3.6 and tables b-2a to b2d first mb 0 set to ??for the ?st macroblock of a slice motion code[0][0][0] to motion code[0][1][1] unde?ed section 2.4.2.7 and table b-4 motion residual[0][0][0] to motion residual[0][1][1] unde?ed section 2.4.2.7;the corresponding rsize bits are extracted from the bitstream and stored as left justi?d; to get the ?al value shift the given number by (8 - corresponding rsize). the rsize values are stored in mp_vld_pi register. start code - copy of the internal start-code register; see section 5. register descr iptions . cbp - section 2.4.3.6 and table b-3 quant scale - section 2.4.2.7
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-14 3.4.1 unexpected start code when vld encounters an unexpected start code, vld sets the ?tart code detected and ?itstream error ?gs (in vld_mc_status register). the start code value is left in the shift register (vld_sr). vld interrupts the cpu, if one of the corresponding interrupt bits in the vld_ie register is enabled 3.4.2 rl over?w if the vld encounters a situation where the last data for a macroblock is being emitted and the run-length code is not 0xff, then the rl over?w error ?g is asserted and an interrupt is generated if the corresponding interrupt enable bit is set. . 3.4.3 flush the ?sh_cmd will be issued in two cases: 1. the bitstream contains error bits for a known amount of bytes and would like to terminate the decoding at a particular byte-offset of the bitstream buffer, and 2. when cpu decides to switch the bitstream at the start of a new slice-start-code in a new row. the cpu will set the dma_input_done_mode bit to ??in the vld_ctl register for the ?st case. the ?sh_cmd will be issued when the vld stops after interrupting the cpu for the dma_input_done reason in the ?st case, and when the vld stops after interrupting the cpu for the start_code_detected reason in the second case. table 8: vld error handling cycle no. action remarks i vld sets the appropriate error bit in the vld_mc_staus register the vld_mc_error signal is formed by or?ng together all of the error bits in the vld_mc_status register is the hence any mc error also drives the vld_mc_error signal high and the following error handling steps still apply i to j when the vld_mc_error signal is high, vld completes any pending control or memory hwy. transactions. the valid data in the dma output buffers will be ?shed to the main memory. then vld asserts the vld_ready_to_reset signal and waits for the cpu to reset. any dma transactions, once started, will not be aborted in the middle k if (vld_ready_to_reset) then the vld interrupts the cpu. assumes k>j; otherwise it is jth cycle. the corresponding interrupt enable (ie) bit in the vld_ie register is ??for the vld to raise the interrupt. l cpu will perform the software reset. refer to section 3.1 for the software reset procedure
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-15 4. application notes 4.0.1 pnx1300 series versus pnx15xx series vld the mpeg-2 macroblock header output format now differs in two ways: the first forward motion vector bit[1] which was unused is now the ?irst macro block?bit, and the sixth word bits[23:16] now contain the slice start code. the pnx1300 series does not implement the ?arse long?command. in the vld_status register, the pnx1300 series does not implement the following bits: bit[6] rl over?w in the vld_control register, the pnx1300 series does not implement the following bits: bit[16] slice_strobe bit[15:8] slice_start_code bit[2] dma_input_done_mode in addition, the little_endian mode bit is on bit[1] in the pnx1300 series; but it is bit[0] in this module. 5. register descriptions 5.1 pnx1300 series and pnx15xx series register differences the current vld is a compatible superset of the vld that was implemented in the pnx1300 series chip. differences in the register de?itions are noted in magenta text. the pnx15xx series implementation removed the rl/mbh write-back dma channels. differences from the current vld implementation are noted in blue text. the base address for the pnx15xx series vld module is 0x07 5000. 5.2 vld register summary table 9: register summary offset symbol description 0x07 5000 vld_command variable length decoder command 0x07 5004 vld_sr vld shift register (shadow) 0x07 5008 vld_qs quantization scale code to be output by the vld 0x07 500c vpd_pi vld picture information 0x07 5010 vld_mc_status vld and mc status register 0x07 5014 vld_ie vld interrupt enable 0x07 5018 vld_ctl vld control register
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-16 5.3 register table 0x07 501c vld_inp_adr vld input memory address 0x07 5020 vld_inp_cnt vld input count gives the number of bytes to be read from main memory 0x07 5024 vld_mbh_adr vld macroblock header writeback address 0x07 5028 vld_mbh_cnt vld macroblock header writeback count 0x07 502c vld_rl_adr vld run-level writeback address 0x07 5030 vld_rl_cnt vld run-level writeback count 0x07 5034 vld_bit_cnt vld bit count gives the number of bits consumed by the vld 0x07 5200 mc_picinfo0 macro-block height 0x07 5ff4 pd power down register 0x07 5ffc module id module identi?ation register table 9: register summary ?ontinued offset symbol description table 10: vld registers bit symbol acces s value description offset 0x07 5000 vld_command 31:12 reserved r 0 11:8 command r/w 0 command code of the vld command to be executed 0x1 = shift bitstream by ?hift count?bits 0x2 = parse macroblock 0x3 = search for next start code 0x4 = reset variable length decoder 0x5 = initialize vld 0x6 = search for the start code given in bits [7:0]. 0x7 = parse macroblock row 0x8 = flush write fifos 0x9 = parse long 7:0 mblock/shift count or start code r/w 0 for the ?hift bitstream command, only the lower 4-bit are used; the upper 4-bit should be set to 0. all 8 bits are used for the ?arse macroblocks?and ?earch for given start code?commands. for parse long command these bits cannot be programmed to 0. offset 0x07 5004 vld_sr 31:15 reserved r 0 15:0 shift register r ni this register is a shadow of the vlds operational shift register and it allows the dspcpu to access the bitstream through the vld. bits 15 through 0 are the current contents of the vld shift register. offset 0x07 5008 vld_qs 31:5 reserved r 0 4:0 quant scale r/w ni this register contains the quantization scale code to be output by the vld until it is overridden by a macroblock quantizer scale code. the quantizer scale code is part of the macroblock header output. offset 0x07 500c vld_pi
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-17 31:28 vertical back. rsize r/w ni number of bits per backward vertical motion vector that are residual in the picture. 27:24 horizontal back. rsize r/w ni number of bits per backward horizontal motion vector that are residual in the picture. 23:20 vertical for. rsize r/w ni number of bits per forward vertical motion vector that are residual in the picture. 19:16 horizontal for. rsize r/w ni number of bits per forward horizontal motion vector that are residual in the picture. 15:14 reserved r 0 13 mpeg2mode r/w ni 1 = indicates if the current sequence is mpeg-2 0 = indicates if the current sequence is mpeg-1 (for error checking only) 12:7 reserved r 0 6 mv_concealment r/w ni 1 = indicates forward motion vectors are coded in all intra macroblock headers of a picture. 0 = indicates forward motion vectors are not coded in all intra macroblock headers of a picture. 5 intra_vlc r/w ni use dct table zero (intra_vlc = ??or one (intra_vlc = ?? 4 frame_prediction_frame _dct r/w ni if 1, motion_type = frame, and dct_type = 0. if 0, motion_type and dct_type follow the decoded values in the mb_header from the vld. cpu should set it to 0 for field pictures and 1 for mpeg-1. 3:2 picture_structure r/w ni 1=top-?ld 2=bottom-?ld 3=frame picture 0=reserved. 1:0 picture_type r/w ni 1=i 2=p 3=b 0=d (mpeg-1 only) offset 0x07 5010 vld_mc_status 31:16 reserved r 0 15:7 reserved r/w 0 6 rl over?w r/w 0 logic ? indicates over?w of run/level values with in a block. refer to section 3.4 error handling for details on the error handling procedure. this bit is cleared by writing a logic ??to it. 5 dma rl output done r/w 0 logic ??indicates that the run length data fifo has been written to main memory. this bit is cleared by writing a logic ??to it. 4 dma header output done r/w 0 logic ??indicates that the run length data fifo has been written to main memory. this bit is cleared by writing a logic ??to it. 3 dma input done r/w 0 conditions for setting this bit depends on the value of the dma_input_done ?ld in the vld_ctl register. refer to t ab le 3 vld control and section 3.3.1 for details. this bit is cleared by writing a logic ??to it. table 10: vld registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-18 2 bitstream error r/w 0 logic ??indicates vld encountered an illegal huffman code or an unexpected start code. refer to section 3.4 error handling for details on the error handling procedure. this bit is cleared by writing a logic ??to it. 1 start code detected r/w 0 logic ??indicates vld encountered 0x000001 while executing current command. this bit is cleared by writing a logic ??to it. 0 vld command done r/w 0 logic ??indicates successful completion of current command. this bit is cleared by issuing a new command. offset 0x07 5014 vld_ie 31:16 reserved 0 15:8 reserved 0 - 7:0 vld int. enables r/w 0 each of these bits enables the matching bit from the vld_status reg 0x010 to issue an ir to the cpu. offset 0x07 518 vld_ctl 31:17 reserved 0 16 slice_start_code_strobe r/w 0 when cpu writes 1 into this ?ld, vld copies the value of slice_start_code into its internal register. cpu should do this only when the vld is stopped. this bit is always read as 0. 15:8 slice_start_code r/w 0 slice start code when the vld is restarted; the slice_start_code_strobe bit field must be set to ? in order to update this ?ld. 7:3 reserved 0 2 dma-input-done-mode r/w 0 when this bit is ?? vld sets the dma_input_done ?g (in vld_mc_status register) when the dma_inp_cnt transitions from non-zero to zero. when this bit is ?? the same ?g is set only with the additional condition that both highway input buffers are empty. the slice_start_code_strobe bit ?ld must be set to ??in order to update this ?ld) 1 reserved r/w 1 0 little_endian r/w 1 force the vld to operate in little endian mode when ?? when set to ??the vld operates in big endian mode. the slice_start_code_strobe bit must be set to ? in order to update this bit. offset 0x07 501c vld_inp_adr 31:0 vld input memory address r/w 0 memory address from which vld is reading (updated when dma read transfer is completed). must be 32-bit word aligned. offset 0x07 5020 vld_inp_cnt 31:15 reserved 0 14:0 vld input count r/w 0 number of bytes to be read from main memory offset 0x07 5024 vld_mbh_adr 31:0 mb header memory address r/w 0 memory address to which the vld writes macroblock headers when vld_ctl[1] is set. must be 32-bit word aligned. table 10: vld registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 21: mpeg-1 and mpeg-2 variable length decoder 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 21-19 offset 0x07 5028 vld_mbh_cnt 31:15 reserved 14:0 mb header count r/w number of mb header bytes to be written to main memory when vld_ctl[1] is set. offset 0x07 502c vld_rl_adr 31:0 vld rl writeback address r/w 0 memory address to which the vld writes run length data when vld_ctl[1] is set. must be 32-bit word aligned. offset 0x07 5030 vld_rl_cnt 31:15 reserved 0 14:0 vld rl count r/w 0 number of rl bytes to be written to main memory when vld_ctl[1] is set. offset 0x07 50034 vld_bit_cnt 31:18 reserved 0 17:0 actual bit count r 0 bits consumed offset 0x07 5ff4 power_down 31 power_down r/w 0 power down indicator 1 = powerdown 0 = power up 30:0 reserved 0 offset 0x07 5ffc module_id 31:16 module id r 0x014d variable length decoder module id register 15:12 major rev r 0 major revision id 11:8 minor rev r 0 minor revision id 7:0 aperture size r 0 aperture = 4 kb table 10: vld registers ?ontinued bit symbol acces s value description
1. introduction the digital video disc (dvd) descrambler allows three major processes: 1. authentication process. 2. key conversion process. 3. main data descrambling process. a dvd player system consists then of a dvd-rom drive which accepts the dvd- rom disc and reads the information from the disc to the drive controller. the drive controller connects the disc transport with an interconnecting bus (pci-xio) and hence to the host system (pnx15xx series). the host system interacts with the dvdd module to send authorization requests, receive authorization, replies, and transfer data between the dvd-rom drive and the dvdd module. 1.1 functional description only customers that have signed an nda may be allowed to receive implementation and programming details. please contact philips semiconductors, inc. nexperia marketing group to obtain the dvd descrambler programming supplement document. a non-disclosure agreement is required. chapter 22: digital video disc descrambler pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 22: digital video disc descrambler 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 22-2
1. introduction the ethernet media access controller (lan100) of the pnx15xx series enables applications to receive and transmit data over an ethernet link. 1.1 features the lan100 is a dma-capable, 10/100 mb/s ethernet media access (mac) controller. it connects to an external ethernet physical layer (phy) chip using a standard media independent interface (mii) or standard reduced mii interface (rmii). the lan100 provides the following functions: receives and transmits ethernet packets via an external phy chip connects to an external phy chip via standard mii or standard reduced mii (rmii) interface implements the mac sublayer of ieee standard 802.3 provides a ?xible choice of fifo buffers and on-chip host buses dma and fifo managers with scatter/gather dma and fifo of frame descriptors memory traf? is optimized by buffering and prefetching receive-packet ?tering includes perfect address matching, hash table, imperfect ?tering, and four pattern-match ?ters. wake-on-lan power management support allows system wake-up, using the receive ?ters or a magic frame detection ?ter supports real-time traf? using time stamps contains dual transmit descriptor buffers, one for real-time traf?, one for non-real-time traf? supports quality-of-service (qos) using a low-priority and a high-priority transmit queue provides vlan support implements ieee 802.3/clause 31 ?w control for both receive and transmit. chapter 23: lan100 ?ethernet media access controller pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-2 2. functional description 2.1 chip i/o and system interconnections figure 1 presents a simpli?d view of the i/o interfaces and system interconnection. on the left-hand side, the lan100 is connected to the off-chip ethernet phy using the media independent interface (mii) or reduced media independent interface (rmii), which includes transmit, receive, and management connections. on the right-hand side, the lan100 is connected to the on-chip system buses: the mmio control port of the lan100 allows cpu access to the lan100s internal registers via the internal dcs bus of the pnx15xx series. the lan100 mmio port is a slave on the dcs bus. the direct memory access (dma) port of the lan100 performs dma via the internal mtl bus of the pnx15xx series. the lan100 can initiate transactions while it is a master on the mtl bus. the lan100 has multiple dma interfaces to allow both non-real-time and real-time transmit modes, and receive mode. figure 1: simpli?d lan100 i/o block diagram phy mtl lan100 cpu memory slave bus master master master slave mmio control dma (r)mii tx (r)mii rx miim bus interface and registers real-time transmit descriptors data status non-real-time transmit descriptors data status receive descriptors data status (r)mii interface dcs bus descriptors data status descriptors data status descriptors data status
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-3 2.2 functional block diagram figure 2 shows a more detailed block diagram of the main internal units of the lan100. primary components of the lan100, shown as blocks outlined in black, are described below. the transmit datapath and receive datapath are shown with unoutlined background colors. the registers provide mmio acces to the lan100. they interface to the transmit and receive data-paths, and to the mii interface. the mii interface connects the lan100 to the off-chip phy. the transmit datapath has two transmit dma managers, dma0 and dma1, which read descriptors and data from memory and write status to memory. in real-time mode, dma0 can be used to handle real-time transmissions and dma1 can be used to handle non-real-time transmissions. in quality-of-service (qos) mode, dma0 has the lowest priority and dma1 has the highest priority. transmission from both of the transmit dma managers is mediated by arbitration logic, including: multiplexers to select one of the transmit dma managers transmit retry module to handle ethernet retry and abort conditions transmit flow control module to insert ethernet pause frames where needed. figure 2: lan100 functional block diagram lan100 miim (r)mii tx (r)mmi rx device registers mmio descriptors data status descriptors data status descriptors data status rx filter rx parser rx dma tx dma1 tx dma0 time-stamp and qos arbiter tx flow control tx retry mii interface tx data tx status rx buffer control abort pass or block packets buffer and abort logic pause frame insertion receive datapath transmit datapath rx parser rx dma tx dma1 tx dma0 tx retry module
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-4 the receive datapath includes: receive parser, which detects packet types by parsing part of the packet header receive ?ter, which can ?ter out certain ethernet packets, applying different ?tering schemes receive buffer, which implements a delay for receive packets to allow the ?ter to ?ter out certain packets before storing them to memory receive dma manager, which reads descriptors from memory and writes data and status to memory. 2.3 description the ethernet media access controller (lan100) and associated device driver software offer the functionality of the media access control (mac) sublayer of the data link layer in the osi reference model (see ieee standard 802.3 [1] ). the mac sublayer transmits and receives frames to and from the next higher protocol level, the mac client layer, typically the logical link control sublayer. the device driver software implements the interface to the mac client layer. it sets up mmio registers in the lan100, maintains fifos of packets in memory, and receives results back from the lan100, typically via interrupts. when packets are transmitted, packet ?lds can be concatenated using the scatter/gather dma functionality of the lan100 to avoid unnecessary data copying. the hardware can add the preamble and start frame delimiter ?lds, and can optionally add the crc under program control. or, software can partially set up the ethernet frames by concatenating the destination address ?ld, source address ?ld, the length/type ?ld, the mac client data ?ld, and optionally, the crc in the frame check sequence ?ld of the ethernet frame. when a packet is received, the lan100 strips the preamble and start frame delimiter and passes the rest of the packet - the rest is the ethernet frame - to the device driver, including destination address, source address, length/type ?ld, mac client data, and frame check sequence. apart from its basic packet management functions, the lan100 contains receive and transmit dma managers that control receive- and transmit-data streams. frames are passed via descriptor fifos (arrays) located in host memory, so that the hardware can process many packets without software or cpu support. packets can consist of multiple fragments that are accessed with scatter/gather dma. the dma managers optimize memory bandwidth by prefetching and buffering. the lan100 is connected to the mtl bus using multiple dma interfaces that perform data buffering to adapt the data burst rate of the mtl bus to the data rate required for the ethernet protocol. the lan100 provides mmio registers via a slave interface to the dcs bus to allow software to access the internal registers of the lan100. real-time traf? is supported using two transmit queues: a real-time queue sends frames at the time speci?d in transmit time-stamps
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-5 a non-real-time queue sends packets immediately. the two transmit queues can also be con?ured to support a generic quality-of-service (qos) system: a high-priority queue provides high quality of service for packets; a low priority queue runs when possible. a receive time-stamp indicates the exact moment in time a packet has been received. receive blocking ?ters are used to identify received packets that are not addressed to this ethernet station, so that they can be discarded. the rx ?ters include a perfect address ?ter, a hash ?ter, and four pattern-matching ?ters. wake-on-lan power management support makes it possible to wake the system up from a power-down state (a state in which some of the clocks are switched off) when wake-up frames are received over the lan. wake-up frames are recognized by the receive ?tering modules or by a magic frame detection technology. system wake-up occurs by triggering an interrupt. an interrupt logic block raises and masks interrupts and keeps track of the cause of interrupts. the interrupt block sends interrupt request signals to the cpu. interrupts can be enabled, cleared, and set by software. support for ieee 802.3/clause 31 ?w control is implemented in the flow control block. receive ?w-control frames are automatically handled by the lan100. transmit ?w-control frames can be initiated by software. in half-duplex mode, the ?w-control module will generate back pressure by sending out continuous preamble only interrupted by pauses to prevent the jabber limit. the lan100 has both a standard ieee 802.3/clause 22 media independent interface (mii) bus and a reduced media independent interface (rmii) to connect to an external ethernet phy chip [3] . mii or rmii mode can be selected by a bit in the lan100 command register. the standard nibble-wide mii interface allows a low-speed data connection to the phy chip at speeds of 2.5 mhz at 10 mbit/s or 25 mhz at 100 mbit/s. the rmii interface allows connection to the phy with low pin-count and double-speed data clock. registers in the phy chip are accessed via the mmio interface through the serial management connection of the mii bus operating at 2.5 mhz. 3. register descriptions 3.1 register summary the base address for lan100 mmio registers begins at offset 0x07,2000 with respect to mmio_base. after a hard or soft reset via the regreset bit of the command register, all bits in all registers are reset to 0, unless shown otherwise in t ab le 2 . reading write-only registers will return a read error. writing read-only registers will return a write error. unused or resrved bits must be ignored on reads and written as 0.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-6 the register map of the lan100 includes mii interface registers and registers for controlling dma transfers, ?w control and ?tering. it also includes interrupt control and module id registers. t ab le 1 provides a summary of all lan100 registers. table 1: lan100 mmio register map offset name r/w function mii interface 0x07 2000 mac1 r/w mac con?uration register 1 0x07 2004 mac2 r/w mac con?uration register 2 0x07 2008 ipgt r/w back-to-back inter-packet gap register 0x07 200c ipgr r/w non b2b inter-packet gap register 0x07 2010 clrt r/w collision window / retry register 0x07 2014 maxf r/w maximum frame register 0x07 2018 supp r/w phy support register 0x07 201c test r/w test register 0x07 2020 mcfg r/w mii management con?uration register 0x07 2024 mcmd r/w mii management command register 0x07 2028 madr r/w mii management address register 0x07 202c mwtd wo mii management write data register 0x07 2030 mrdd ro mii management read data register 0x07 2034 mind ro mii management indicators register 0x07 2038 reserved 0x07 203c reserved 0x07 2040 sa0 r/w station address 0 register 0x07 2044 sa1 r/w station address 1 register 0x07 2048 sa2 r/w station address 2 register 0x07 204c to 0x07 20fc reserved control registers 0x07 2100 command r/w command register 0x07 2104 status ro status register 0x07 2108 rxdescriptor r/w receive descriptor base address register 0x07 210c rxstatus r/w receive status base address register 0x07 2110 rxdescriptornumber r/w number of receive descriptors register 0x07 2114 rxproduceindex ro receive produce index register 0x07 2118 rxconsumeindex r/w receive consume index register 0x07 211c txdescriptor r/w non real-time transmit descriptor base address register 0x07 2120 txstatus r/w non real-time transmit status base address register
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-7 0x07 2124 txdescriptornumber r/w non real-time number of transmit descriptors (minus one encoded) register 0x07 2128 txproduceindex r/w non real-time transmit produce index register 0x07 212c txconsumeindex ro non real-time transmit consume index register 0x07 2130 txrtdescriptor r/w real-time transmit descriptor base address register 0x07 2134 txrtstatus r/w real-time transmit status base address register 0x07 2138 txrtdescriptornumbe r r/w number of real-time transmit descriptors register (minus-one encoded) 0x07 213c txrtproduceindex r/w real-time transmit produce index register 0x07 2140 txrtconsumeindex ro real-time transmit consume index register 0x07 2144 blockzone r/w block zone for real-time mode register 0x07 2148 qostimeout r/w time-out for qos mode register 0x07 214c reserved 0x07 2150 reserved 0x07 2154 reserved 0x07 2158 tsv0 ro first part of mii interface transmit status register 0x07 215c tsv1 ro second part of mii interface transmit status register 0x07 2160 rsv ro receive status from mii interface register 0x07 2164 to 0x07 216c reserved 0x07 2170 flowcontrolcounter r/w flow control mirror and pause timer register 0x07 2174 flowcontrolstatus ro flow control internal mirror counter 0x07 2178 to 0x07 21f8 reserved 0x07 21fc globaltimestamp ro global time-stamp counter rx filter registers 0x07 2200 rxfilterctrl r/w receive filter control 0x07 2204 rxfilterwolstatus ro receive filter wake-on-lan status 0x07 2208 rxfilterwolclear wo receive filter wake-on-lan status clear 0x07 220c patternmatchjoin r/w join method for pattern matching filters 0x07 2210 hashfilterl r/w bit 31:0 of hash table 0x07 2214 hashfilterh r/w bit 63:32 of hash table 0x07 2218 to 0x07 222c reserved for hash table extension table 1: lan100 mmio register map offset name r/w function
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-8 in qos mode, that is, when the enableqos bit of the command register is set, the real-time transmit registers correspond to the registers of the low-priority transmit channel and the non-real-time transmit registers correspond to the registers of the high priority transmit channel. 3.2 register de?itions this section de?es the bits of the individual lan100 registers. the mii interface registers are mapped to addresses in the range 0x07 2000 ?0x07 20fc. for more information about the mii interface registers than is provided here, please refer to [2] . 0x07 2230 patternmatchmask0l r/w bit 31:0 of pattern match 0 0x07 2234 patternmatchmask0h r/w bit 63:32 of pattern match 0 0x07 2238 patternmatchcrc0 r/w crc value for pattern match 0 0x07 223c patternmatchskip0 r/w skip bytes for pattern match 0 0x07 2240 patternmatchmask1l r/w bit 31:0 of pattern match 1 0x07 2244 patternmatchmask1h r/w bit 63:32 of pattern match 1 0x07 2248 patternmatchcrc1 r/w crc value for pattern match 1 0x07 224c patternmatchskip1 r/w skip bytes for pattern match 1 0x07 2250 patternmatchmask2l r/w bit 31:0 of pattern match 2 0x07 2254 patternmatchmask2h r/w bit 63:32 of pattern match 2 0x07 2258 patternmatchcrc2 r/w crc value for pattern match 2 0x07 225c patternmatchskip2 r/w skip bytes for pattern match 2 0x07 2260 patternmatchmask3l r/w bit 31:0 of pattern match 3 0x07 2264 patternmatchmask3h r/w bit 63:32 of pattern match 3 0x07 2268 patternmatchcrc3 r/w crc value for pattern match 3 0x07 226c patternmatchskip3 r/w skip bytes for pattern match 3 0x07 2270 to 0x07 2fdc reserved standard registers 0x07 2fe0 intstatus ro interrupt status register 0x07 2fe4 intenable r/w interrupt enable register 0x07 2fe8 intclear wo interrupt clear register 0x07 2fec intset wo interrupt set register 0x07 2ff0 reserved 0x07 2ff4 powerdown r/w power-down register 0x07 2ff8 reserved 0x07 2ffc moduleid ro module id table 1: lan100 mmio register map offset name r/w function
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-9 table 2: lan100 registers bit symbol acces s value description mii interface registers offset 0x07 2000 mac con?urationuration register 1 (mac1) 31:16 - - 0 unused 15 soft_reset r/w 1 setting this bit puts all modules within the mii interface into the reset state. mii interface registers are not reset. it has no effect upon lan100 components other than the mii interface. clearing this bit restores the mii interface to operation. its default value is 1 (reset). 14 simulation_reset r/w 0 setting this bit will reset the random number generator within the transmit function of the mii interface. 13:12 - - 0 unused 11 reset_pemcs/rx r/w 0 setting this bit puts the mac control sublayer / rx domain logic into the reset state. 10 reset_perfun r/w 0 setting this bit puts the receive function logic in the reset state. 9 reset_pemcs_tx r/w 0 setting this bit puts the mac control sublayer / tx domain logic in the reset state. 8 reset_petfun r/w 0 setting this bit puts the mii interface transmit function logic in the reset state. 7:5 - - 0 unused 4 loopback r/w 0 setting this bit causes the mac transmit interface to be looped backed to the mac receive interface. clearing this bit results in normal operation. 3 tx_flow_control r/w 0 when set, pause flow control frames are allowed to be transmitted. when cleared, flow control frames are blocked. 2 rx_flow_control r/w 0 when set, the mac acts upon received pause flow control frames. when cleared, received pause flow control frames are ignored. 1 pass_all_receive_ frames r/w 0 when set, the mac will indicate pass current receive frame for all frames regardless of type (normal vs. control). when cleared, the mac deasserts pass current receive frame for valid control frames. 0 receive_enable r/w 0 set this bit to enable receiving frames. internally, the mac synchronizes this control bit to the incoming receive stream and outputs synchronized receive enable, to be used by the host system to qualify receive frames. offset 0x07 2004 mac con?uration register 2 (mac2) 31:16 - - 0 unused 14 excess_defer r/w 0 when set, the mac will defer to carrier inde?itely as per the standard [1] . when cleared, the mac will abort when the excessive deferral limit is reached, and will provide feedback to the host system. 13 back_pressure r/w 0 when set, the mac after incidentally causing a collision during back pressure will immediately retransmit without backoff, reducing the chance of further collisions and ensuring transmit packets get sent.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-10 12 no_backoff r/w 0 when set, the mac will immediately retransmit following a collision rather than using the binary exponential backoff algorithm as speci?d in the standard [1] . 11:10 - - 0 unused 9 long_preamble_ enforcement r/w 0 when set, the mac only allows receive packets which contain preamble ?lds less than 12 bytes in length. when cleared, the mac allows any length preamble as per the standard [1] . 8 pure_preamble_ enforcement r/w 0 when set, the mac will verify the content of the preamble to ensure it contains 0x55 and is error-free. packets with errors in the preamble are discarded. 7 auto_detect_pad_ enable r/w 0 set this bit to cause the mac to automatically detect the type of frame, either tagged or un-tagged, by comparing the two octets following the source address with 0x8100 (vlan protocol id) and pad accordingly. for more information refer to the mii interface documentation. [2] 6 vlan pad enable r/w 0 set this bit to cause the mac to pad all short frames to 644 bytes and append a valid crc. for more information, refer to the mii interface documentation. [2] 5 pad_crc_enable r/w 0 set this bit to have the mac pad all short frames. clear this bit if frames presented to the mac have a valid length. this bit is used in conjunction with auto_detect_pad_enable and vlan_pad_ enable. 4 crc_enable r/w 0 set this bit to append a cyclic redundancy check (crc) to every frame, whether padding was required or not. this bit must be set if pad_crc_enable is set. clear this bit if frames presented to the mac contain a crc. 3 delayed_crc r/w 0 this bit determines the number of bytes, if any, of proprietary header information that exist on the front of ieee 802.3 frames. for more information refer to the mii interface documentation. [2] 2 huge_frame_ enable r/w 0 when set, frames of any length can be transmitted and received. 1 frame_length_ checking r/w 0 when set, both transmit and receive frame lengths are compared to the length/type ?ld. if the length/type ?ld represents a length, then the check is performed. mismatches are reported on the transmit/receive statistics vector. 0 full_duplex r/w 0 when set, the mac operates in full-duplex mode. disable for half-duplex operation. offset 0x07 2008 back-to-back inter-packet-gap register (ipgt) 31:7 - - 0 unused table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-11 6:0 back_to_back_ inter_packet_gap r/w 0 this is a programmable ?ld representing the nibble time offset of the minimum possible period between the end of any transmitted packet, to the beginning of the next. in full-duplex mode, the register value should be the desired period in nibble times minus 3. in half-duplex mode, the register value should be the desired period in nibble times minus 6. in full-duplex, the recommended setting is 0x15 (21 decimal), which represents the minimum ipg of 0.96 ms (in 100 mb/s) or 9.6 ms (in 10 mb/s). in half-duplex the recommended setting is 0x12 (18 decimal), which also represents the minimum ipg of 0.96 ms (in 100 mb/s) or 9.6 ms (in 10 mb/s). offset 0x07 200c non back-to-back inter-packet-gap register (ipgr) 31:15 - 0 - unused 14:8 non_back_to_ back_inter_ packet_gap_part_1 0 r/w this is a programmable ?ld representing the optional carriersense window referenced in ieee 802.3 section 4.2.3.2.1 titled ?arrier deference? if carrier is detected during the timing of ipgr1, the mac defers to carrier. if, however, carrier becomes active after ipgr1, the mac continues timing ipgr2 and transmits, knowingly causing a collision, thus ensuring fair access to the medium. its range of values is 0x0 to ipgr2. 7 - 0 - unused 6:0 non_back_to_ back_inter_ packet_gap_part_2 0x12 r/w this is a programmable ?ld representing the non-back-to-back inter-packet-gap. the default is 0x12 (18 decimal), which represents the minimum ipg of 0.96 ms (in 100 mb/s) or 9.6 ms (in 10 mb/s). offset 0x07 2010 collision window / retry register (clrt) 31:14 - - 0 unused 13:8 collision_window r/w 0x37 this is a programmable ?ld representing the slot time or collision window during which collisions occur in properly con?ured networks. since the collision window starts at the beginning of transmission, the preamble and sfd is included. its default of 0x37 (55 decimal) corresponds to the count of frame bytes at the end of the window. 7:4 - 0 unused 3:0 retransmission_ maximum r/w 0xf this is a programmable ?ld specifying the number of retransmission attempts following a collision before aborting the packet because of excessive collisions. the standard speci?s the attemptlimit to be 0xf (15 decimal). offset 0x07 2014 maximum frame register (maxf) 31:16 - - 0 unused 15:0 maximum_frame_ length r/w 0x0600 this ?lds reset value is 0x0600, which represents a maximum receive frame of 1536 octets. an untagged maximum size ethernet frame is 1518 octets. a tagged frame adds four octets for a total of 1522 octets. if a shorter maximum length restriction is desired, program this 16-bit ?ld. offset 0x07 2018 phy support register (supp) the supp register is only relevant if an smii, rmii, pmd or endec interface is provided to the phy. 31:16 - - 0 unused table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-12 15 reset_pesmii r/w 0 this bit resets the serial mii logic. 14:13 - - 0 unused 12 phy_mode r/w 1 this bit con?ures the serial mii logic with the connecting smii device type. set this bit when connecting to a smii phy. clear this bit when connecting to a smii mac. when mac is selected, the smii will operate at 100 mb/s, full duplex. 11 reset_permii r/w 0 this bit resets the reduced mii logic. 10:9 - - 0 unused 8 speed r/w 0 this bit con?ures the reduced mii logic for the current operating speed. when set, 100 mb/s mode is selected. when cleared, 10 mb/s mode is selected. 7 reset_pe100x r/w 0 this bit resets the pe100x module which contains the 4b/5b symbol encipher/decipher logic. this effects the pe100x module only. 6 force_quiet r/w 0 when set, transmit data is quieted, which allows the contents of the cipher to be output. when cleared, normal operation is enabled. effects pe100x module only. 5 no_cipher r/w 0 when set, the raw transmit 5b symbols are transmitted without ciphering. when cleared, normal ciphering occurs. effects pe100x module only. 4 disable_link_fail r/w 0 when set, the 330ms link fail timer is disabled allowing for shorter simulations. removes the 330 ms link-up time before reception of streams is allowed. when cleared, normal operation occurs. effects pe100x module only. 3 reset_pe10t r/w 0 this bit resets the pe10t module which converts mii nibble streams to the serial bit stream of 10t transceivers. effects pe10t module only. 2 - - 0 unused 1 enable_jabber_ protection r/w 0 this bit enables the jabber protection logic within the pe10t in endec mode. jabber is the condition where a transmitter is stuck on for longer than 50ms to prevent other stations from transmitting. effects pe10t module only. 0 bit_mode r/w 0 when set, the mac is in 10base-t endec mode, which changes decodes (such as excess_defer) to be based on the bit clock rather than the nibble clock. offset 0x07 201c test register (test) 31:3 - - 0 unused 2 test_ backpressure r/w 0 setting this bit will cause the mac to assert back pressure on the link. back pressure causes the preamble to be transmitted, raising carrier sense. a transmit packet from the system will be sent during back pressure. 1 test_pause r/w 0 this bit causes the mac control sublayer to inhibit transmissions, just as if a pause receive control frame with a non-zero pause time parameter was received. 0 shortcut_pause_ quanta r/w 0 this bit reduces the effective pause quanta from 64 byte-times to 1 byte-time. table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-13 offset 0x07 2020 mii mgmt con?uration (mcfg) 31:16 - - 0 unused 15 reset_mii_mgmt r/w 0 for more information refer to the mii interface documentation [2] . 14:5 - - 0 unused 4:2 clock_select r/w 0 this ?ld is used by the clock divide logic to create the mii management clock (mdc) which ieee 802.3u de?es to be no faster than 2.5 mhz. some phys support clock rates up to 12.5 mhz, however. for more information refer to the mii interface documentation [2] . 1 suppress_ preamble r/w 0 for more information refer to the mii interface documentation [2] . 0 scan_increment r/w 0 for more information refer to the mii interface documentation [2] . offset 0x07 2024 mii mgmt command (mcmd) 31:2 - - 0 unused 1 scan r/w 0 this bit causes the mii management module to perform read cycles continuously. this is useful for monitoring the link fail timer, for example. 0 read r/w 0 this bit causes the mii management module to perform a single read cycle. the read data is returned in register mrdd (mii mgmt read data). offset 0x07 2028 mii mgmt address (madr) 31:13 - - 0 unused 12:8 phy_address r/w 0 this ?ld represents the 5-bit phy address ?ld of management cycles. up to 31 phys can be addressed (0 is reserved). 7:5 - - 0 unused 4:0 register_address r/w 0 this ?ld represents the 5-bit register address ?ld of management cycles. up to 32 registers can be accessed. offset 0x07 202c mii mgmt write data (mwtd) 31:16 - - 0 unused 15:0 write_data wo 0 when written, an mii management write cycle is performed using the 16-bit data and the pre-con?ured phy and register addresses from register (0x0a). offset 0x07 2030 mii mgmt read data (mrdd)\ 31:16 - - 0 unused 15:0 read_data ro 0 following a mii management read cycle, the 16-bit data can be read from this location. offset 0x07 2030 mii mgmt read data (mrdd)\ 31:3 - - 0 unused 2 not_valid ro 0 when set, this bit indicates the mii management read cycle has not completed, and the read data is not yet valid. 1 scanning ro 0 when set, this bit indicates a scan operation (continuous mii management read cycles) is in progress. table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-14 0 busy ro 0 when set, this bit indicates the mii management module is currently performing an mii management read or write cycle. offset 0x07 2040 station address (sa0) 31:16 - - 0 unused 15:8 station_address_ 1st_octet r/w 0 this ?ld holds the ?st octet of the station address. 7:0 station_address__ 2nd_octet r/w 0 this ?ld holds the second octet of the station address. offset 0x07 2044 station address (sa1) 31:16 - - 0 unused 15:8 station_address_ 3rd_octet r/w 0 this ?ld holds the third octet of the station address. 7:0 station_address_ 4th_octet r/w 0 this ?ld holds the fourth octet of the station address. offset 0x07 2048 station address (sa2) 31:16 - - 0 unused 15:8 station_address_ 5th_octet r/w 0 this ?ld holds the ?th octet of the station address. 7:0 station_address_ 6th_octet r/w 0 this ?ld holds the sixth octet of the station address. offset 0x07 2100 command register (command) 31:12 - - unused 11 enableqos r/w 0 when set, the arbiter operates in qos mode, in which the real-time transmit channel has low priority and the non-real-time channel has high priority 10 fullduplex r/w 0 when set, indicates full-duplex operation. 9 rmii r/w 0 when set, indicates rmii mode; if clear, then mii mode. 8 txflowcontrol r/w 0 enable ieee 802.3 / clause 31 ?w control sending pause frames in full duplex and continuous preamble in half duplex. 7 passrxfilter r/w 0 when set to ?? disables receive ?tering, i.e., all packets received are written to memory. 6 passruntframe r/w 0 when set to ?? runt frame packets smaller than 64 bytes are passed to memory unless they have a crc error. if set to ?? runt frames are ?tered out. 5 rxreset wo 0 if set, reset the receive datapath. 4 tx reset wo 0 if set, reset the transmit datapath. 3 regreset wo 0 if set, reset all datapaths and the host registers. the mii interface must be reset separately. 2 txrtenable r/w 0 enable the real-time transmit datapath. 1 txenable r/w 0 enable the non-real-time transmit datapath. 0 rxenable r/w 0 enable the receive datapath. offset 0x07 2104 status register (status) table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-15 the values represent the status of the three channels/datapaths. in case the status is 1 the channel is active meaning it: is enabled and the rx/txrt/txenable bit is set in the command register or it just got disabled while still transmitting or receiving a frame and for transmit channels the transmit queue is not empty i.e. produceindex != consumeindex and for the receive channel the receive queue is not full i.e. produceindex != consumeindex - 1 the status transitions from active to inactive if the channel is disabled by software resetting the tx/rt/txrtenable bit in the command register and if the channel has committed the status and data of the current frame to memory. the status also transition to inactive if the transmit queue is empty or if the receive queue is full and status and data have been committed to memory. 31:3 - - unused 2 txrtstatus ro if ?? the real-time transmit datapath is active. if ?? the channel is inactive. 1 txstatus ro if ?? non-real-time transmit datapath is active. if ?? the channel is inactive. 0 rxstatus ro if ?? the receive datapath is active, if ?? the channel is inactive. offset 0x07 2108 receive descriptor base address register (rxdescriptor) the receive descriptor base address is a byte address aligned to a word boundary, (i.e. the two lsbs of the address are ?ed to 0). the register contains the lowest address in the array of descriptors. 31:2 rxdescriptor r/w 0 msbs of receive descriptor base address. 1:0 - ro 0 fixed to 0. offset 0x07 210c receive status base address register (rxstatus) the receive status base address is a byte address aligned to a double word boundary i.e. lsb 2:0 are ?ed to 3?000. 31:3 rxstatus r/w 0 msbs of receive status base address. 2:0 - ro 0 fixed to 0. offset 0x07 2110 receive number of descriptors register (rxdescriptornumber) this register de?es the number of descriptors in the descriptor array for which rxdescriptor is the base address. the number of descriptors should match the number of states. the register uses minus-one encoding, i.e. if the array has 8 status elements, the value in the register should be 7. 31:16 - - unused 15:0 rxdescriptornumber r/w 0 number of descriptors in the descriptor array for which rxdescriptor is the base address. the number of descriptors is minus-one encoded. offset 0x07 2114 receive produce index (rxproduceindex) this register indexes the descriptor that is going to be ?led next by the receive datapath. after a packet has been received, hardware increments the index and wrapps to 0 when the value of rxdescriptornumber has been reached. if the rxproduceindex equals rxconsumeindex 1, the array is full, and any further packets being received will cause a buffer overrun error. 31:16 - - unused 15:0 rx produce index ro index of the descriptor that is going to be ?led next by the receive datapath. offset 0x07 2118 receive consume index (rxconsumeindex) table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-16 this register indexes the descriptor that is to be processed next by the software receive driver. the receive array is empty as long as rxproduceindex equals rxconsumeindex. as soon as the array is not empty, software can process the packet pointed to by rxconsumeindex. after a packet has been processed by software, software should increment the rxconsumeindex register, wrapping to 0 once the rxdescriptornumber has been reached. if the rxproduceindex equals rxconsumeindex 1, the array is full, and any further packets being received will cause a buffer overrun error. 31:16 - - unused 15:0 rxconsumeindex r/w 0 index of the descriptor that is going to be processed next by the receive software. offset 0x07 211c non-real-time transmit descriptor base address register (txdescriptor) this register is a byte address aligned to a word boundary (i.e. the two lsbs are ?ed to 0). the register contains the lowest address in the array of descriptors. 31:2 txdescriptor r/w 0 msbs of non-real-time descriptor base address 1:0 - ro 0 fixed to 2?00 offset 0x07 2120 non-real-time transmit status base address register (txstatus) this register is a byte address aligned to a double word boundary (i.e., the three lsbs are ?ed to 0). the register contains the lowest address in the array of statuses. 31:3 txstatus r/w 0 msbs of non-real-time transmit status base address 2:0 - ro 0 fixed to 0 offset 0x07 2124 non-real-time transmit number of descriptors register (txdescriptornumber) this register de?es the number of descriptors in the descriptor array for which txdescriptor is the base address. the number of descriptors should match the number of statuses. the register uses minus-one encoding, i.e., if the array has 8 status elements, the value in the register should be 7. 31:16 - - unused 15:0 txdescriptornumber r/w 0 number of descriptors in the descriptor array for which txdescriptor is the base address. the register is minus-one encoded offset 0x07 2128 non-real-time transmit produce index (txproduceindex) this register de?es the descriptor that is going to be ?led next by the software transmit driver. the transmit descriptor array is empty as long as txproduceindex equals txconsumeindex. as soon as the array is not empty, the non-real-time transmit hardware will start transmitting packets, if enabled. after a packet has been processed by software, software should increment the txproduceindex, wrapping to 0 once the txdescriptornumber has been reached. if the txproduceindex equals txconsumeindex 1, the descriptor array is full and software should stop producing new descriptors until hardware has transmitted some packets and updated the txconsumeindex. 31:16 - - unused 15:0 txproduceindex r/w 0 index of the descriptor that is going to be ?led next by the non-real-time transmit software driver. offset 0x07 212c non-real-time transmit consume index (txconsumeindex) this register de?es the descriptor that is going to be transmitted next by the hardware non-real-time transmit process. after a packet has been transmitted, hardware increments the index, wrapping to 0 once txdescriptornumber has been reached. if the txconsumeindex equals txproduceindex, the descriptor array is empty, and the transmit channel will stop transmitting until software produces new descriptors. 31:16 - - unused 15:0 txconsumeindex ro index of the descriptor that is going to be transmitted next by the non-real-time transmit datapath. offset 0x07 2130 real-time transmit descriptor base address register (txrtdescriptor) table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-17 this register is a byte address aligned to a word boundary (i.e., the two lsbs are ?ed to 0). the register contains the lowest address in the array of descriptors. 31:2 txrtdescriptor r/w msbs of real-time descriptor base address. 1:0 - 0 fixed to 0. offset 0x07 2134 real-time transmit status base address register (txrtstatus) this register is a byte address aligned to a double word boundary (i.e., the three lsbs are ?ed to 0). the register contains the lowest address in the array of status words. 31:3 txrtstatus r/w msbs of real-time transmit status base address. 2:0 - 0 fixed to 0. offset 0x07 2138 real-time transmit number of descriptors register (txrtdescriptornumber) this register de?es the number of descriptors in the descriptor array for which txrtdescriptor is the base address. the number of descriptors should match the number of statuse words. the register uses minus-one encoding, i.e., if the array has 8 status elements, the value in the register should be 7. 31:16 - - unused 15:0 txrtdescriptornumber r/w 0 number of descriptors in the descriptor array for which txrtdescriptor is the base address. the number of descriptors is minus-one encoded. offset 0x07 213c real-time transmit produce index register (txrtproduceindex) this register de?es the descriptor that is going to be ?led next by the software transmit driver. the transmit descriptor array is empty as long as txrtproduceindex equals txrtconsumeindex. as soon as the array is not empty, the real-time transmit hardware will start transmitting packets, if enabled. after a packet has been processed by software, software should increment the txrtproduceindex, wrapping to 0 once txrtdescriptornumber has been reached. if the txrtproduceindex equals txrtconsumeindex ?1, the descriptor array is full, and software should stop producing new descriptors until hardware has transmitted some packets and updated the txrtconsumeindex. 31:16 - - unused 15:0 txrtproduceindex r/w 0 index of the descriptor that is going to be ?led next by the real-time transmit software driver. offset 0x07 2140 real-time transmit consume index register (txrtconsumeindex) this register de?es the descriptor that is going to be transmitted next by the hardware real-time transmit process. after a packet has been transmitted, hardware increments the index, wrapping to 0 once txrtdescriptornumber has been reached. if the txrtconsumeindex equals txrtproduceindex, the descriptor array is empty, and the transmit channel will stop transmitting until software produces new descriptors. 31:16 - - unused 15:0 txrtconsumeindex ro index of the descriptor that is going to be transmitted next by the real-time transmit datapath. offset 0x07 2144 transmit block zone register (blockzone) the blockzone register is only used in real-time/non-real-time arbitration mode, i.e., when the enableqos bit in the command register is deasserted. the blockzone register de?es a window before a real-time transmission time-stamp in which no new non-real-time transmissions can be started, so as to free up the ethernet for a pending real-time transmission. the size of the blockzone window in seconds is: blockzone * t time-stamp clock no new non-real-time transfers will be started if: descriptortimestamp < globaltimestamp + blockzone the real-time transmission will start as soon as: descriptortimestamp < globaltimestamp. 31:16 - - unused table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-18 15:0 blockzone r/w 0 time margin for a transmit time-stamp during which no new non-real-time packets will be transmitted to free up the ethernet for upcoming real-time transmissions. offset 0x07 2148 transmit quality of service time-out register (qostimeout) the qostimeout register is only used in qos mode, i.e., when the qosenable bit of the command register is set. 31:16 - - unused 15:0 qostimeout r/w speci?s the maximum number of clock cycles a low-priority transmission must wait for transmission. if the time-out counter expires, the low-priority transmission will get the highest priority. qostimeout is speci?d in units of 64 times the transmit clock cycle. offset 0x07 2158 transmit status vector 0 register (tsv0) the transmit status vector registers tsv0 and tsv1 store the most recent transmit status returned by the mii interface. since the status vector consists of more than 4 bytes, status is distributed over two registers: tsv0 and tsv1. 31 vlan ro set if the frames length/type ?ld contained 0x8100, which is the vlan protocol identi?r. 30 backpressure ro set if carrier-sense method back pressure was previously applied. 29 pause ro set if the frame was a control frame with a valid pause opcode. 28 control frame ro set if the frame was a control frame. 27-12 total bytes ro the total number of bytes transferred, including collided attempts. 11 underrun ro set if the host side caused a buffer underrun condition. 10 giant ro set if the byte count in the frame was greater than [15:0]. 9 latecollision ro set if a collision occurred beyond the collision window (512 bit times). 8 maximumcollision ro if set, the packet was aborted because it exceeded the maximum allowed number of collisions. 7 excessivedefer ro if set, the packet was deferred in excess of 6071 nibble times in 100mb/s, or 24287 bit times in 10mb/s mode. 6 packetdefer ro if set, the packet was deferred for at least one attempt, but less then an excessive defer. 5 broadcast ro set if the packets destination was a broadcast address. 4 multicast ro set if the packets destination was a multicast address. 3 done ro indicates that the transmission of the packet was completed. 2 lengthoutofrange ro indicates that the frame type/length ?ld was larger than 1500 bytes. 1 lengthcheckerror ro indicates that the frame length ?ld does not match the actual number of data items, and is not a type ?ld. 0 crcerror ro set if the attached crc in the packet did not match the crc generated internally. offset 0x07 215c transmit status vector 0 register (tsv1) the transmit status vector registers tsv0 and tsv1 store the most recent transmit status returned by the mii interface. since the status vector consists of more than 4 bytes, status is distributed over two registers: tsv0 and tsv1. 31:20 - - unused table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-19 19:16 transmitcollisioncount ro the number of collisions the current packet incurred during transmission attempts. the maximum number of collisions (16) cannot be represented. 15:0 transmitbytecount ro the total number of bytes in the frame not counting the collided bytes. offset 0x07 2160 receive status vector register (rsv) the receive status vector register stores the most recent receive status returned by the mii interface. 31 - - unused 30 vlan ro the frames length/type ?ld contained 0x8100, which is the vlan protocol identi?r. 29 unsupportedopcode ro the current frame was recognized as a control frame, but it contains an unknown opcode. 28 pause ro the frame was a control frame with a valid pause opcode. 27 controlframe ro the frame was a control frame. 26 dribblenibble ro indicates that after the end of packet, another 1-7 bits were received. a single nibble, called the ?ribble nibble,?is formed but not sent out. 25 broadcast ro the packets destination was a broadcast address. 24 multicast ro the packets destination was a multicast address. 23 receiveok ro the packet had valid crc and no symbol errors. 22 lengthoutofrange ro indicates that the frame type/length ?ld was larger than 1518 bytes. 21 lengthcheckerror ro indicates that the frame length ?ld does not match the actual number of data items, and is not a type ?ld. 20 crcerror ro the attached crc in the packet did not match the crc generated internally. 19 receivecodeviolation ro indicates that mii data does not represent a valid receive code when lan_rx_er is asserted during the data phase of a frame. 18 carriereventpreviouslys een ro indicates that at some time since the last receive statistics, a carrier event was detected. 17 rxdveventpreviouslys een ro indicates that the last receive event seen was not long enough to be a valid packet. 16 packetpreviouslyignored ro indicates that a packet since the last rsv was dropped. 15:0 receivedbytecount ro indicates length of received frame. offset 0x07 2170 flow control counter register (flowcontrolcounter) 31:16 pausetimer r/w in full-duplex mode, the pausetimer ?ld speci?s the value that is inserted into the pause timer ?ld of a pause ?w control frame. in half-duplex mode, the pausetimer ?ld speci?s the number of backpressure cycles. 15:0 mirrorcounter r/w in full-duplex mode, the mirrorcounter speci?s the number of cycles to wait before reissuing the pause control frame. in half-duplex mode, the mirrorcounter allows to keep on sending out the preamble until txflowcontrol is de-asserted. offset 0x07 2174 flow control status register (flowcontrolstatus) table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-20 31:16 - - unused 15:0 mirrorcountercurrent ro in full-duplex mode, this register represents the current value of the datapaths mirror counter which counts up to the value of the mirrorcounter bits from the flowcontrolcounter register. in half-duplex mode, the datapaths mirror counter counts until it reaches the value of the pausetimer bits in the flowcontrolcounter register. offset 0x07 21fc global time-stamp register (globaltimestamp) the global time-stamp register records the 32-bit running value of the global time-stamp clock. internally, the counter is used to generate the time-stamp ?ld in the transmit/receive status ?lds. in the real-time transmit mode, it is used as a reference for the transmit arbiter. 31:0 globaltimestamp ro binary (not grey-coded) value of the global time-stamp counter. offset 0x07 2200 receive filter control register (rxfilterctrl) 31:14 - - unused 13 rxfilterenwol r/w when set, the result of the perfect address matching ?ter, the imperfect hash ?ter, and the pattern match ?ter will generate a wol interrupt in case of a match. 12 magicpacketenwol r/w when set, the result of the magic packet ?ter will generate a wol interrupt in case of a match. 11:8 patternmatchen r/w each of the four bits enables one of the pattern-matching ?ter units. the lowest order bit corresponds to ?ter unit 0. 7 andor r/w the and/or relation between the pattern-matching ?ter and the accepting group of bits below. if set, the result of the pattern match ?ter is anded with the ored results of the accepting group below. when set to 0, the result of the pattern-matching ?ter is ored with the ored results of the accepting group below. see section 5.2 . 6 - - unused 5 acceptperfecten r/w when set to ?? the packets with an address identical to the station address are accepted. 4 acceptmulticasthashen r/w when set to ?? multicast packets that pass the imperfect hash ?ter are accepted. 3 acceptunicasthashen r/w when set to ?? unicast packets that pass the imperfect hash ?ter are accepted. 2 acceptmulticasten r/w when set to ?? all multicast packets are accepted. 1 acceptbroadcasten r/w when set to ?? all broadcast packets are accepted. 0 acceptunicasten r/w when set to ?? all unicast packets are accepted. offset 0x07 2204 receive filter wol status register (rxfilterwolstatus) the bits in this register store the cause for a wol. status can be cleared by writing the rxfilterwolclear register. 31:9 - - unused 8 magicpacketwol ro when set to ?? a magic packet ?ter caused wol. 7 rxfilterwol ro when set to ?? the receive ?ter caused wol. 6 patternmatchwol ro when set to ?? the pattern-matching ?ter caused wol. 5 acceptperfectwol ro when set to ?? the perfect address-matching ?ter caused wol. table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-21 4 acceptmulticasthashwo l ro when set to ?? a multicast packet that passed the imperfect hash ?ter caused wol. 3 acceptunicasthashwol ro when set to ?? a unicast packet that passed the imperfect hash ?ter caused wol. 2 acceptmulticastwol ro when set to ?? a multicast packet caused wol. 1 acceptbroadcastwol ro when set to ?? a broadcast packet caused wol. 0 acceptunicastwol ro when set to ?? a unicast packet caused wol. offset 0x07 2208 receive filter wol clear register (rxfilterwolclear) the bits in this register are write-only; writing resets the corresponding bits in the rxfilterwolstatus register. 31:9 - - unused 8 magicpacketwolclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 7 rxfilterwolclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 6 patternmatchwolclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 5 acceptperfectwolclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 4 acceptmulticasthashwo lclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 3 acceptunicasthashwol clr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 2 acceptmulticastwolclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 1 acceptbroadcastwolclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. 0 acceptunicastwolclr wo when set, the corresponding status bit in the rxfilterwolstatus register is cleared. offset 0x07 220c pattern matching join register (patternmatchjoin) see section 3.3 on page 23- 25 for a description of the functions of this register. see t ab le 3 for a description of the join operation code ?lds. 31:24 - - unused 23:20 join0123 r/w control bits for joining the result of join012 and join123. 19:16 join123 r/w control bits for joining the result of join12 and join23. 15:12 join012 r/w control bits for joining the result of join01 and join12. 11:8 join23 r/w control bits for joining the result of pattern-matching ?ter units 2 and 3. 7:4 join12 r/w control bits for joining the result of pattern-matching ?ter units 1 and 2. 3:0 join01 r/w control bits for joining the result of pattern-matching ?ter units 0 and 1. offset 0x07 2210 hash ?ter table lsbs register (hashfilterl) table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-22 31:0 hashfilterl r/w bit 31:0 of the imperfect ?ter hash table for receive ?tering. offset 0x07 2214 hash ?ter table msbs register (hashfilterh) 31:0 hashfilterh r/w bit 63:32 of the imperfect ?ter hash table for receive ?tering. offset 0x07 2230/40/50/60 patternmatch unit 0/1/2/3 mask lsbs register (patternmatchmask0/1/2/3l) the patternmatchmask registers specify a mask for the pattern matching windows so that some bytes can be masked out in the crc calculation. the patternmatchmask consists of 64 byte-enable signals, one for each byte in the pattern-matching window. the pattern-matching mask is distributed over two 32-bit registers. the lan100 has four pattern-matching units. 31:0 patternmatchmask0/1/2/ 3l r/w bits 31:0 of the pattern-matching mask for ?ter unit 0/1/2/3. each bit represents a byte-enable in the pattern-matching window. offset 0x07 2234/44/54/64 patternmatch unit 0/1/2/3 mask msbs register (patternmatchmask0/1/2/3h) the patternmatchmask registers specify a mask for the pattern matching windows so that some bytes can be masked out in the crc calculation. the patternmatchmask consists of 64 byte-enable signals, one for each byte in the pattern-matching window. the pattern matching mask is distributed over two 32-bit registers. the lan100 has four pattern-matching units. 31:0 patternmatchmask0/1/2/ 3h r/w bits 63:32 of the pattern-matching mask for ?ter unit 0/1/2/3. each bit represents a byte-enable in the pattern-matching window. offset 0x07 2238/48/58/68 patternmatch unit 0/1/2/3 crc register (patternmatchcrc0/1/2/3) each of the four pattern-matching ?ters calculates a 32-bit crc on a 64-byte window. if the crc matches the 32-bit golden crc value in the ?ter units crc register, a match is found. 31:0 patternmatchcrc0/1/2/ 3 r/w the golden crc for pattern-matching ?ter unit 0/1/2/3. offset 0x07 223c/4c/5c/6c patternmatch unit 0/1/2/3 skip bytes (patternmatchskip0/1/2/3) each of the four pattern-matching ?ters calculates a 32-bit crc on a 64-byte window. the window can have an offset with respect to the start of the frame. the pattern match unit 0/1/2/3 skip bytes register speci?s the number of bytes that must be skipped before starting the window. 31:0 patternmatchskip0/1/2/3 r/w the number of bytes in a frame that need to be skipped before starting pattern-matching ?tering in unit 0/1/2/3. offset 0x07 2fe0 interrupt status register (intstatus) the interrupt status register is read-only. bits can be set via the intset register. bits can be cleared via the intclear regis ter. 31:14 - - unused 13 wakeupint ro interrupt was triggered by a wakeup event detected by the receive ?ter. 12 softint ro interrupt was triggered by software writing a 1 in the intset register. 11 txrtdoneint ro interrupt was triggered because a real-time descriptor was transmitted and the interrupt bit in its descriptor was set. 10 txrtfinishedint ro interrupt was triggered because all real-time descriptors have been processed, so that now produceindex == consumeindex. 9 txrterrorint ro interrupt was triggered on real-time transmit errors: latecollision, excessivecollision, excessivedefer, and nodescriptor or underrun. 8 txrtunderrunint ro interrupt set on a fatal underrun error in the real-time transmit queue. the fatal interrupt should be resolved by a tx soft-reset. the bit is not set in case of a non fatal underrun error. table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-23 7 txdoneint ro interrupt was triggered because a non-real-time descriptor was transmitted and the interrupt bit in its descriptor was set. 6 txfinishedint ro interrupt was triggered because all non-real-time descriptors have been processed, so that now produceindex == consumeindex. 5 txerrorint ro interrupt was triggered on non-real-time transmit errors: latecollision, excessivecollision, excessivedefer, and nodescriptor or underrun. 4 txunderrunint ro interrupt set on a fatal underrun error in the non real-time transmit queue. the fatal interrupt should be resolved by a tx soft-reset. the bit is not set in case of a non fatal underrun error. 3 rxdoneint ro interrupt was triggered because a receive descriptor has been processed and the interrupt bit in its descriptor was set. 2 rxfinishedint ro interrupt was triggered because all receive descriptors have been processed, so that now produceindex == consumeindex. 1 rxerrorint ro interrupt was triggered on receive errors: alignmenterror, rangeerror, lengtherror, symbolerror, crcerror, or nodescriptor or overrun. 0 rxoverrunint ro interrupt was triggered on fatal overrun error in the receive queue. the fatal interrupt should be resolved by a rx soft-reset. the bit is not set in case of a non fatal underrun error. offset 0x07 2fe4 interrupt enable register (intenable) 31:14 - - unused 13 wakeupinten r/w enable interrupts triggered by a wakeup event detected by the receive ?ter. 12 softinten r/w enable interrupts triggered when software writes a 1 to the int_set softinterrupt register. 11 txrtdoneinten r/w enable interrupts triggered when a real-time descriptor has been transmitted while the control.interrupt bit in the descriptor was set. 10 txrtfinishedinten r/w enable triggering interrupts when all real-time descriptors have been processed, when produceindex == consumeindex. 9 txrterrorinten r/w enable interrupts on real-time transmit errors. 8 txrtunderruninten r/w enable interrupts on real-time transmit buffer or descriptor underrun conditions. 7 txdoneinten r/w enable interrupts when a non-real-time descriptor has been transmitted and the interrupt bit in its descriptor was set. 6 txfinishedinten r/w enable interrupts when all non-real-time descriptors have been processed, when produceindex == consumeindex. 5 txerrorinten r/w enable interrupts on non-real-time transmit errors. 4 txunderruninten r/w enable interrupts on non-real-time transmit buffer or descriptor underrun conditions. 3 rxdoneinten r/w enable interrupts when a receive descriptor has been processed and the interrupt bit in its descriptor was set. 2 rxfinishedinten r/w enable interrupts when all receive descriptors have been processed, when produceindex == consumeindex. table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-24 1 rxerrorinten r/w enable interrupts on receive errors. 0 rxoverruninten r/w enable interrupts on receive buffer overrun or descriptor underrun conditions. offset 0x07 2fe8 interrupt clear register (intclear) the interrupt clear register is write-only. writing a 1 to a bit of the register clears the corresponding bit in the status register. writing a 0 to a bit of the register does not affect the corresponding interrupt status. 31:14 - - unused 13 wakeupintset wo writing a 1 clears the corresponding status bit in intstatus. 12 softintset wo writing a 1 clears the corresponding status bit in intstatus. 11 txrtdoneintset wo writing a 1 clears the corresponding status bit in intstatus. 10 txrtfinishedintset wo writing a 1 clears the corresponding status bit in intstatus. 9 txrterrorintset wo writing a 1 clears the corresponding status bit in intstatus. 8 txrtunderrunintset wo writing a 1 clears the corresponding status bit in intstatus. 7 txdoneintset wo writing a 1 clears the corresponding status bit in intstatus. 6 txfinishedintset wo writing a 1 clears the corresponding status bit in intstatus. 5 txerrorintset wo writing a 1 clears the corresponding status bit in intstatus. 4 txunderrunintset wo writing a 1 clears the corresponding status bit in intstatus. 3 rxdoneintset wo writing a 1 clears the corresponding status bit in intstatus. 2 rxfinishedintset wo writing a 1 clears the corresponding status bit in intstatus. 1 rxerrorintset wo writing a 1 clears the corresponding status bit in intstatus. 0 rxoverrunintset wo writing a 1 clears the corresponding status bit in intstatus. offset 0x07 2fec interrupt set register (intset) the interrupt set register is write-only. writing a 1 to a bit of the register sets the corresponding bit in the status registe r. writing a 0 to a bit of the register does not affect the interrupt status. 31:14 - - unused 13 wakeupintset wo writing a 1 sets the corresponding status bit in intstatus. 12 softintset wo writing a 1 sets the corresponding status bit in intstatus. 11 txrtdoneintset wo writing a 1 sets the corresponding status bit in intstatus. 10 txrtfinishedintset wo writing a 1 sets the corresponding status bit in intstatus. 9 txrterrorintset wo writing a 1 sets the corresponding status bit in intstatus. 8 txrtunderrunintset wo writing a 1 sets the corresponding status bit in intstatus. 7 txdoneintset wo writing a 1 sets the corresponding status bit in intstatus. 6 txfinishedintset wo writing a 1 sets the corresponding status bit in intstatus. 5 txerrorintset wo writing a 1 sets the corresponding status bit in intstatus. 4 txunderrunintset wo writing a 1 sets the corresponding status bit in intstatus. 3 rxdoneintset wo writing a 1 sets the corresponding status bit in intstatus. 2 rxfinishedintset wo writing a 1 sets the corresponding status bit in intstatus. 1 rxerrorintset wo writing a 1 sets the corresponding status bit in intstatus. 0 rxoverrunintset wo writing a 1 sets the corresponding status bit in intstatus. table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-25 3.3 pattern matching join register the pattern matching join register (patternmatchjoin) de?es the way the outputs of the four pattern-matching sections are joined together into a single pattern-matching result. joining is done by a pyramid architecture in three stages. the ?st stage offset 0x07 2ff4 power-down register (powerdown) the powerdown register is used to block all mmio access except access to the powerdown register. setting the bit will return an error on all register access except for access to the powerdown register. in case the lan100 is in a power-down state because, for example, no phy is connected, then software should set the powerdown bit in the powerdown register in order to prevent deadlock (for example, due to a speculative read operation of the cpu). 31 powerdown r/w if set, all register access will return a read/write error except accesses to the powerdown register. 30:0 - - unused offset 0x07 2ffc module id register (moduleid) the moduleid register is used to store standard philips module id information. 31:16 moduleid ro 0x3902 unique 16-bit module identi?ation. 15:12 majrev ro 0x1 major design revision number. 11:8 minrev ro 0x1 minor design revision number. 7:0 aperturesize ro 0 represents the aperture of the software registers in the mmio register space. aperture size is 4 kb, corresponding to a value 0 in this ?ld. table 2: lan100 registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-26 consists of three join modules, the second stage consists of two modules and the ?al stage consists of one module, as depicted in figure 3 . each join module can produce a single result from two inputs while doing a logic function on the two inputs. each of the join modules has four inputs matcha , matchb and readya , readyb and two outputs matcho and readyo . the ready output is the logic and of the ready inputs ( readyo = readya & readyb ). the match output of a join module depends on the two match inputs and a logic function that can be programmed via four bits in the patternmatchjoin register. the pattern in each nibble of that register de?es the logic function the join module performs on the inputs to produce the output. t ab le 3 lists the bit de?itions of the patternmatchjoin register. figure 3: pattern matching join function table 3: patternmatchjoin register nibble functions nibble (binary) name function 0000 b a & b logic and 0001 b a & !b logic and not 0010 b !a & b logic not and 0011 b !a & !b logic not and not 0100 b !(a & b) logic not or not 0101 b !(a & !b) logic not or 0110 b !(!a & b) logic or not 0111 b !(!a & !b) logic or 1000 b a ^ b logic xor 1001 b !(a ^ b) logic xnor 1010 b a feedthrough a rdy match match rdy match rdy match rdy patternmatch0 patternmatch1 patternmatch2 patternmatch3 [3:0] [15:12] [11:8] [7:4] [19:16] [23:20] join01 &, |, ! join12 &, |, ! join23 &, |, ! join012 &, |, ! join123 &, |, ! join0123 &, |, ! match rdy hrrxpatternmatchjoin[32:0] joinxxxx &, |, ! rdya matcha rdyb matchb rdyo matcho rdyo
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-27 4. descriptor and status formats this section de?es the descriptor format for the transmit and receive scatter/gather dma engines. each ethernet packet can be broken into a set of fragments . each fragment will have a single corresponding descriptor. the dma managers in the lan100 can scatter (for receive) and gather (for transmit) multiple fragments into a single ethernet packet. 4.1 receive descriptors and status figure 4 depicts the layout of the receive descriptors in memory. the receive descriptors are stored in an array in memory. the base address of the array is stored in the rxdescriptor register. the number of descriptors in the array is stored in the rxdescriptornumber register using a minus-one encoding format. for example, if the array has 8 elements, the rxdescriptornumber register value should 1011 b b feedthrough b 1100 b !a invert a 1101 b !b invert b 1110 b 0 fix match output to zero 1111 b 1 fix match output to one table 3: patternmatchjoin register nibble functions ?ontinued nibble (binary) name function figure 4: receive descriptor memory layout packet control data buffer statusinfo statustimestamp rxdescriptor rxstatus rxdescriptornumber 1 2 3 4 5 packet control data buffer statusinfo statustimestamp packet control data buffer statusinfo statustimestamp packet control data buffer statusinfo statustimestamp packet control data buffer statusinfo statustimestamp packet control data buffer statusinfo statustimestamp
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-28 be 7. for each element of the descriptor array, there is an associated status ?ld in the status array. the base address of the status array is stored in the rxstatus register. during operation, that is, when the receive datapath is enabled, the rxdescriptor, rxstatus and rxdescriptornumber registers should not be modi?d. the base address of the descriptor array as stored in the rxdescriptor register should be aligned on an 8-byte address boundary. the status array base address in the rxstatus register must be aligned on an 8-byte address boundary. the rxconsumeindex and rxproduceindex registers contain counters that start at 0 and wrap back around to 0 when they equal rxdescriptornumber. the rxproduceindex indexes the descriptor that will be ?led by the next packet received by the lan100. it is incremented by the hardware. the rxconsumeindex is programmed by software, and is the index of the next descriptor that the software receive driver is going to process. if rxproduceindex == rxconsumeindex, then the receive buffer is empty. if rxproduceindex == rxconsumeindex 1 then the receive buffer is full, and newly received data would generate an over?w unless the software driver frees up some descriptors. each receive descriptor structure requires two words (8 bytes) of memory. likewise each receive status structure requires two words (8 bytes) of memory. receive descriptor structures consist of a packet word containing a pointer to a data buffer for storing receive data and a control word. the address offset of the packet word in the receive descriptor structure is 0, and the address offset of the control word is offset by 4 bytes with respect to the receive descriptor structure address, as de?ed in t ab le 4 . the packet word is a 32-bit byte-aligned address value containing the base address of the data buffer. the de?ition of the control word bits are given in t ab le 5 . table 4: receive descriptor structure name address offset size function packet 0x0 31:0 base address of the data buffer for storing receive data. control 0x4 31:0 control information, see t ab le 5 . table 5: receive descriptor control word bit name function 31 interrupt if set, generate an rxdone interrupt when the data in this packet or packet fragment and the associated status information has been committed to memory. 30:11 unused 10:0 size size in bytes of the data buffer. this is the size of the buffer reserved by the device driver for a packet or packet fragment, i.e., the byte size of the buffer pointed to by the packet word. the size is ? encoded, e.g., if the buffer is 8 bytes, the size ?ld should be equal to 7.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-29 t ab le 6 lists the components of the receive status structure. each receive status structure consists of two words. the statustimestamp word contains a copy of the time-stamp counter value at the time the reception completed. if the fragment is not the last fragment of the packet, the status re?cts the value of the time-stamp when the fragment buffer was ?led completely. if the fragment is the last in a multi-packet reception, the time-stamp will be a copy of the time-stamp counter at the moment the mii interface generates the status. the statusinfo word contains ?gs returned by the mii interface and ?gs generated by the receive datapath re?cting the status of the reception. t ab le 7 lists the bit de?itions in the statusinfo word. table 6: receive status structure name address offset size function statusinfo 0x0 31:0 receive status return ?gs, see table 7 statustimestamp 0x4 31:0 time-stamp of the receive completion table 7: receive status information word bit name function 31 error an error occurred during reception of this packet. this is a logic or of alignmenterror, rangeerror, lengtherror, symbolerror and crcerror. 30 lastfrag when set, this bit indicates this descriptor is the last fragment of a packet. if the packet consists of a single fragment, this bit is also set. 29 nodescriptor no new rx descriptor is available, and the frame is too long for the buffer size in the current receive descriptor. 28 overrun receive overrun. the adapter can not accept the data stream or the status stream. 27 alignmenterro r an alignment error is ?gged when dribble bits are detected or a crc error is detected. this is in accordance with ieee std. 802.3/clause 4.3.2. (see rsv[26] & rsv[20].) 26 rangeerror the received packet exceeds maximum packet size. (see rsv[22].) 25 lengtherror the frame length ?ld value in the packet does not match the actual data byte-length, and speci?s an invalid length. (see rsv[21].) 24 symbolerror the phy reports a bit error over the mii interface during reception. (see rsv[19].) 23 crcerror crc error. (see rsv[20].) 22 broadcast the received packet is of type broadcast. (see rsv[25].) 21 multicast a multicast packet has been received. (see rsv[24].) 20 failfilter indicates this packet has failed the rx ?ter. these packets are not supposed to pass to memory. but because of the limitation of buffer fifo size, part of this packet may already have been passed to memory. once the packet was found to have failed the rx ?ter, the remainder of the packet will be discarded without passing to memory. however, if command.passrxfilter is set, the whole packet will be passed to memory. 19 vlan indicates a vlan frame. (see rsv[30].)
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-30 for multi-fragment packets, the value of the alignmenterror, rangeerror, lengtherror, symbolerror and crcerror bits in all but the last fragment in the packet will be 0; likewise the value of the failfilter, multicast, broadcast, vlan and controlframe bits is unde?ed. the status of the last fragment in the packet will copy the value for these bits from the mii interface. all fragment statuses will have a valid lastfrag, entrylevel, error, overrun and nodescriptor bits. 4.2 transmit descriptors and status figure 5 shows the layout of transmit descriptors in memory. the layout and format of real-time and non-real-time descriptors is identical. 18 controlframe indicates this is a control frame for ow control, either a pause frame or a frame with an unsupported opcode. 17:11 - unused 10:0 entrylevel size in bytes of the actual data transferred into one fragment buffer. in other words, this is the size of the packet or fragment as actually written by the dma manager for one descriptor. this may be different from the control.size bits that indicate the size of the buffer allocated by the device driver. size is ? encoded, e.g., if the buffer has 8 bytes the entrylevel value should be 7. table 7: receive status information word bit name function figure 5: transmit descriptor memory layout tx(rt)status 0xfeedb1f8 packet 0xfeedb314 control 0 07 time-stamp pad descriptor 0 tx(rt)descriptor 0xfeedb0ec 0xfeedb0ec 0xfeedb0f8 0xfeedb118 0xfeedb0fc 0xfeedb008 descriptor array 0xfeedb10c 0xfeedb11c 0xfeedb128 0xfeedb314 packet 0 header (8 bytes) 0xfeedb411 0xfeedb41c packet 0 payload (12 bytes) 0xfeedb32b 0xfeedb1f8 statusinfo statustimestamp status 0 0xfeedb200 0xfeedb208 0xfeedb210 packet 0xfeedb411 control 0 07 time-stamp pad descriptor 1 packet 0xfeedb419 control 0 07 time-stamp pad descriptor 2 packet 0xfeedb324 control 0 07 time-stamp pad descriptor 3 packet 1 header (8 bytes) 0xfeedb324 tx(rt)consumeindex tx(rt)produceindex tx(rt)descriptorindex statusinfo statustimestamp statusinfo statustimestamp statusinfo statustimestamp status 1 status 2 status 3 status array 0xfeedb31b descriptor array fifo fragment buffers status array fifo
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-31 for each of the two transmit channels, the transmit descriptors are stored in an array in memory. the base address of the non-real-time transmit descriptor array is stored in the txdescriptor register. likewise for real-time transmissions, the descriptor array base address is stored in the txrtdescriptor register. the number of descriptors in the array is stored in the tx(rt)descriptornumber register using minus-one encoding, for example, if the array has 8 elements the register value should be 7. parallel to the descriptors, there is an array for status. for each element of the descriptor array, there is an associated status ?ld in the status array. the base address of the status array is stored in the tx(rt)status register. during operation, that is, when the transmit datapath is enabled, the tx(rt)descriptor, tx(rt)status and tx(rt)descriptornumber registers should not be modi?d. the base address of the descriptor array, as stored in the tx(rt)descriptor register, must be aligned on a 16-byte address boundary. the status array base address, as stored in the tx(rt)status register, must be aligned on an 8-byte address boundary. the txconsumeindex and txproduceindex registers are counters that start at 0 and wrap back to 0 when they equal txdescriptornumber, which indicates the number of descriptors that have been processed in the non-real-time transmit channel. the txrtconsumeindex and txrtproduceindex perform the same function for the real-time channel. the tx(rt)produceindex contains the index of the next descriptor that is going to be ?led by the software driver. the tx(rt)consumeindex contains the index of the next descriptor that is going to be transmitted by the hardware. if tx(rt)produceindex == tx(rt)consumeindex, then the transmit buffer is empty. if tx(rt)produceindex == tx(rt)consumeindex 1, then the transmit buffer is full, and the software driver cannot add new descriptors unless the hardware has transmitted some packets and freed up some descriptors. as shown in t ab le 8 , each transmit descriptor structure takes four word locations (16 bytes) of memory. likewise each transmit status structure takes two words (8 bytes) in memory. each transmit descriptor structure consists of a packet word that points to the data buffer containing transmit data, a control word and a timestamp word used for real-time transmission. for non-real-time transmission, the timestamp word is ignored. the pad word is always ignored and is just used to align the descriptors on a 16-byte boundary. the packet ?ld has a zero address offset, the control ?ld has a 4-byte address offset, the time-stamp ?ld has an 8 byte offset with respect to the descriptor address. table 8: transmit descriptor fields name address offset siz e function packet 0x0 31:0 base address of the data buffer containing transmit data. control 0x4 31:0 control information, see t ab le 9 . timestam p 0x8 31:0 time stamp for real-time transmission. this time stamp indicates the moment when this packet is to be transmitted. pad 0xc 31:0 unused word to pad to 8 byte boundary.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-32 the packet word is a 32-bit byte-aligned address value containing the base address of the data buffer. the time-stamp ?ld is a 32-bit value which is compared against the internal time-stamp counter for real-time transmission. the de?ition of the control word bits is listed in t ab le 9 . t ab le 10 lists the ?lds in the transmit status structure. the transmit status structure consists of two words. the statustimestamp word contains a copy of the time-stamp counter value at the time the transmit status structure was received from the mii interface. if the fragment is not the last fragment in the packet, the time-stamp value will be a copy of the time-stamp counter at the time all data in the fragment was accepted by the tx retry module. the statusinfo table 9: transmit descriptor control word bit name function 31 interrupt if set, generate an tx(rt)done interrupt when the data in this packet or packet fragment has been sent and the associated status information has been committed to memory. 30 last if set, this bit indicates that this is the descriptor for the last fragment in the receive packet. if not set, the fragment from the next descriptor should be appended. 29 crc if set, append a hardware crc to the packet. 28 pad if set, pad short packets to 64 bytes. 27 huge if set, this bit enables huge frames. when not set, this bit prevents transmission of more than maxf[15:0]. when set, it allows unlimited frame sizes. 26 override per-packet override. if set, bits [30:27] override the defaults from the mii interface internal registers. if not set, control bits [30:27] will be ignored and the default values from the mii interface will be used. 25:11 unused 10:0 size size in bytes of the data buffer. this is the size of the packet or fragment as it must be fetched by the dma manager. in most cases, it will be equal to the byte size of the data buffer pointed to by the packet ?ld of the descriptor. size is ? encoded, e.g., a buffer of 8 bytes is encoded as the size value 7. table 10: transmit status structure name address offset siz e function statusinfo 0x0 31:0 transmit status return ?gs, see t ab le 11 . statustimestamp 0x4 31:0 time-stamp of transmit completion.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-33 word contains ?gs returned by the lan100 and ?gs generated by the transmit datapath re?cting the status of the transmission. t ab le 11 lists the bit de?itions in the statusinfo word. for multi-fragment packets, the value of the latecollision, excessivecollision, excessivedefer, defer and collissioncount bits in all but the last fragment in the packet will be 0. the status of the last fragment in the packet will copy the value for these bits from the mii interface. all fragment statuses will have valid error, nodescriptor and underrun bits. 5. lan100 functions this section de?es the functions of the lan100. after introducing the dma concepts and giving a description of the basic transmit and receive functions, this section covers such advanced features as ?w control, receive ?tering, and the like. 5.1 mmio interface 5.1.1 overview the lan100 mmio interface is connected to the dcs system control bus so that the host registers are visible from the cpu. the mmio interface allows device driver software on the cpu to interact with the lan100. the mmio interface has a 32-bit datapath and an address aperture of 4kb. it only supports word accesses. t ab le 1 on page 23- 6 lists the lan100 registers. table 11: transmit status information word bit name function 31 error an error occurred during transmission. this is a logic or of latecollision, excessivecollision and excessivedefer. 30 nodescriptor the tx stream is interrupted, because a descriptor is not available. 29 underrun a tx underrun occurred because the adapter did not produce transmit data or the adapter is not accepting statuses. 28 latecollision an out-of-window-collision was seen, causing packet abort. (see tsv[29].) 27 excessivecollision indicates this packet exceeded the maximum collision limit and was aborted. (see tsv[28].) 26 excessivedefer this packet incurred deferral beyond the maximum deferral limit and was aborted. (see tsv[27].) 25 defer this packet incurred deferral, because the medium was occupied. this is not an error unless excessive deferral occurs. (see tsv[26].) 24:21 collisioncount the number of collisions this packet incurred, up to the retransmission maximum. (see tsv[19:16].) 20:0 - unused
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-34 the mmio interface will return a read error if an mmio read operation accesses a write-only register; likewise a write error is returned if an mmio write operation accesses to the read-only register. an mmio read or write error will be returned on mmio read or write accesses to reserved registers. if the powerdown bit of the powerdown register is set, all mmio read and write accesses will return a read or write error except for accesses to the powerdown register. 5.2 direct memory access 5.2.1 descriptor fifos the lan100 includes three high-performance dma managers. the dma managers make it possible to transfer packets directly to and from memory with little support from the processor, and without the need to trigger an interrupt for each packet. the dma managers work with fifos of packet descriptor structures and status structures that are stored in host memory. the descriptor structures and status structures act as an interface between the ethernet hardware module and the device driver software. there is one descriptor fifo for receive packets and there are two descriptor fifos for transmit packets, one for real-time transmit traf?, and one for non-real-time transmit traf?. by separating the areas in memory where the device driver and ethernet module each carry out write operations, it is easy to maintain memory coherency and to make the descriptors cache safe , so that cache memory can be used to store descriptors. using caching and buffering for packet descriptors, the memory traf? and memory bandwidth utilization of descriptors can be kept small. this makes the descriptor format scalable to high speeds, including gigabit ethernet. each packet descriptor structure contains a pointer to a data buffer containing a packet or packet fragment, a control word, a status word, and a time stamp for real-time transmit. the software driver determines the memory locations of the descriptor and status arrays and writes their base addresses in the txdescriptor, txrtdescriptor, rxdescriptor and txstatus, txrtstatus, rxstatus registers. the number of descriptor structures and status structures in each array should be written in the txdescriptornumber, txrtdescriptornumber and rxdescriptornumber registers. the number of descriptor structures in an array should correspond to the number of status structures in the associated status array. descriptor structure arrays must be aligned on a 4-byte (32-bit) address boundary; status structure arrays must be aligned on an 8-byte (64-bit) address boundary. 5.2.2 ownership of descriptors both device driver software and ethernet hardware can read and write the descriptor fifos simultaneously to produce and consume descriptors. a descriptor is either owned by the device driver or it is owned by the ethernet hardware. only the owner of a descriptor reads or writes its value. typically, the sequence of use and ownership of descriptor structures and status structures is as follows: a descriptor structure is owned and set up by the device driver
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-35 ownership of the descriptor structure and corresponding status structure is passed by the device driver to the ethernet module, which reads the descriptor structure and writes information to the status structure. the ethernet module passes ownership of the descriptor structure back to the device driver, which uses the information in the status structure and then recycles both to be used for another packet. software must pre-allocate the arrays used to implement the fifos. software can hand over ownership of descriptor structures and status structures to the hardware by incrementing the txproduceindex, txrtproduceindex, and rxconsumeindex registers, wrapping around to 0 if the array boundary is crossed. hardware hands over descriptor structures and status structures to hardware by updating the txconsumeindex, txrtconsumeindex, and rxproduceindex registers. after handing over a descriptor to the receive and transmit dma hardware, device driver software should not modify the descriptor or reclaim the descriptor by decrementing the txproduceindex, txrtproduceindex, and rxconsumeindex registers, because descriptors may have been prefetched by the hardware. in this case the device driver software will have to wait until the packet has been transmitted. or, the device driver can perform soft-reset of the transmit and/or receive datapaths, which will also reset the descriptor fifos. 5.2.3 sequential order with wrap-around descriptors are read from the arrays, and statuses are written to the arrays, in sequential order with wrap-around. sequential order means that when the ethernet module has ?ished reading or writing a descriptor or status, the next descriptor or status it reads or writes is the one at the next higher, adjacent memory address. wrap-around means that when the ethernet module has ?ished reading or writing the last descriptor or status of the array (with the highest memory address), the next descriptor or status it reads or writes is the ?st descriptor or status of the array at the base address of the array. 5.2.4 full and empty state of fifos the descriptor fifos can be empty , partially full or full . a fifo is empty when all descriptors are owned by the producer. a fifo is partially full if both producer and consumer own part of the descriptors and both are busy processing those descriptors. a fifo is full when all descriptors (except one) are owned by the consumer, so that the producer has no more room to process packets. ownership of descriptors is indicated with the use of a consume index and a produce index . the produce index is the ?st element of the array owned by the producer. it is also the index of the array element that is next going to be used by the producer of packets (which may already be busy using it and subsequent elements). the consume index is the ?st element of the array that is owned by the consumer. it is also the number of the array element next to be consumed by the software (which may already be busy consuming it and subsequent elements). if the consume index and the produce index are equal, the fifo is empty, and all array elements are owned by the producer. if the consume index equals the produce index plus one, then the array is full and all array elements (except the one at the
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-36 produce index) are owned by the consumer. one array element is kept empty even with a full fifo, so that it is easy to distinguish the full or empty state by looking at the value of the produce index and consume index. an array must have at least two elements to be able to indicate a full fifo with a produce index of value 0 and a consume index of value 1. the wrap-around of the arrays is taken into account when determining if a fifo is full, so a produce index that indicates the last element in the array and a consume index that indicates the ?st element in the array also means the fifo is full. when the produce index and the consume index are unequal and the consume index is not the produce index plus one (with wrap around taken into account), then the fifo is partially full and both the consumer and producer own enough descriptors to be able to operate actively on the fifo. 5.2.5 interrupt bit the descriptor structures have an interrupt bit, which if enabled, can be programmed by software to interrupt the cpu when a packet with this bit set is processed. when the ethernet module is processing a descriptor and ?ds this bit set, it will cause an interrupt to be triggered (after committing status to memory) by setting the rxdoneint, txdoneint or txrtdoneint bits in the intstatus register and driving an interrupt to the cpu. if the interrupt bit is not set in the descriptor, then the rxdoneint, txdoneint or txrtdoneint are not set, and no interrupt is triggered. note: the corresponding bits in intenable must also be set to trigger interrupts. this offers ?xible ways of managing the descriptor fifos. for instance, the device driver could add 10 packets to the tx descriptor fifo and set the interrupt bit in descriptor number 5 in the fifo. this would invoke the interrupt service routine before the transmit fifo is completely exhausted. the device driver could add another batch of packets to the descriptor array without interrupting continuous transmission of packets. 5.2.6 packet fragments for maximum ?xibility in packet storage, packets can be split up into multiple packet fragments with fragments located in different places in memory. in this case, one descriptor is used for each packet fragment. thus, a descriptor can point to a single packet or to a fragment of a packet. fragments allow for scatter/gather dma operations: transmit packets are gathered from multiple fragments in memory receive packets can be scattered to multiple fragments in memory. by stringing together fragments, it is possible to create large packets from small memory areas. another use of fragments is to be able to locate a packet header and packet body in different places and to concatenate them without copy operations in the device driver. for transmission, the last bit in the descriptor control ?ld indicates if the fragment is the last in a packet; for receive packets the last bit in the statusinfo ?ld of the status words indicates if the fragment is the last in the packet. if the last bit is 0, the next descriptor belongs to the same ethernet packet, if the last bit is 1 the next descriptor is a new ethernet packet.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-37 5.3 initialization after reset, the lan100 software driver must initialize the lan100 hardware. during initialization the software must: con?ure the phy via the mii management interface (miim) select rmii or mii mode con?ure the transmit and receive dma engines con?ure the host registers (mac1,mac2, etc.) in the mii interface remove the soft reset condition from the mii interface enable the receive and transmit datapaths depending on the phy connected to the lan100, the software must initialize registers in the phy via the mii management interface. the software can read and write phy registers by programming the mcfg, mcmd, and madr registers of the lan100. write data should be written to the mwtd register; read data and status information can be read from the mrdd and mind registers. the lan100 supports rmii and mii phys. during initialization, software must select mii or rmii mode by programming the command register. after initialization, the rmii or mii mode should not be modi?d. transmit and receive dma engines should be initialized by the device driver, allocating the descriptor and status arrays in memory. real-time transmit, non-real-time transmit, and receive each have their own dedicated descriptor and status arrays. the base addresses of these arrays must be programmed in the txdescriptor/txstatus, txrtdescriptor/txrtstatus and rxdescriptor/rxstatus registers. the number of descriptor structures in an array should match the number of status structures. please note that the transmit descriptor structures are 16 bytes each while the receive descriptor structures and status structures of both receive and transmit are 8 bytes each. all descriptor arrays must be aligned on 4-byte boundaries; status arrays must be aligned on 16-byte boundaries. the number of descriptors in the descriptor arrays must be written to the txdescriptornumber, txrtdescriptornumber, and rxdescriptornumber registers using a 1 encoding, that is, the value in the registers is the number of descriptors minus one. for example, if the descriptor array has 4 descriptors, the value of the number of descriptors register should be 3. after setting up the descriptor arrays, packet buffers must be allocated for the receive descriptors before enabling the receive datapath. the packet ?ld of the receive descriptors must be ?led with the base address of the packet buffer of that descriptor. among others, the control ?ld in the receive descriptor must contain the size of the data buffer using ? encoding. the receive datapath has a con?urable ?tering function for discarding or ignoring speci? ethernet packets. the ?tering function should also be con?ured during initialization. after a hard reset, the soft reset bit in the mii interface will remain asserted. before enabling the lan100, the soft reset condition must be removed.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-38 the receive function is enabled in two steps. the receive dma manager must be enabled and the receive datapath of mii interface must be enabled. to prevent over?w in the receive dma engine, it should be enabled by setting the rxenable bit in the command register before enabling the receive datapath in the mii interface by setting the receive_enable bit in the mac1 register. the non-real-time and real-time transmit dma engine can be enabled any time by setting the txenable and txrtenable bits in the command register. before enabling the datapaths, several options can be programmed, such as automatic ?w control, transmit-to-receive loop-back for veri?ation, full- or half-duplex modes, and so forth. base addresses of fifos and fifo sizes cannot be modi?d without soft reset of the receive and transmit datapaths. 5.4 transmit process 5.4.1 overview this section outlines the transmission process. the lan100 has two transmit datapaths which can be con?ured as real-time, non-real-time, high- or low priority. for more information on non-real-time and low- or high-priority transmission, please refer to section 5.8 . in the following subsections the pre? txrt refers to the real-time/low-priority transmit datapath and the pre? tx refers to the non-real-time/high-priority transmit datapath. 5.4.2 device driver sets up descriptors and data before setting up one or more descriptors for transmission, the device driver should select if the packet should go to the real-time or non-real-time fifo. real-time traf? or low-priority qos traf? should go to the real-time tx descriptor fifo while non-real-time or high-priority qos traf? should go to the non-real-time tx descriptor fifo. if the selected descriptor fifo is full, the device driver should wait for the fifo to become not full before writing the descriptor in the fifo. if the selected fifo is not full, the device driver should use the descriptor indexed by txproduceindex from the array pointed to by txdescriptor (or the descriptor indexed by txrtproduceindex from the txrtdescriptor array for real-time/low priority qos). the packet pointer in the descriptor is set to point to a data packet or packet fragment to be transmitted. the size ?ld in the command ?ld of the descriptor should be set to the number of bytes in the fragment buffer, ? encoded. additional control information can be indicated in the control ?ld in the descriptor (including bits for interrupt, last, crc, and pad). the time-stamp ?ld in the descriptor must be initialized for real-time transmissions. after writing the descriptor, it must be handed over to the hardware by incrementing (and possibly wrapping) the txproduceindex or txrtproduceindex registers. if the transmit datapath is disabled, the device driver should not forget to enable the (non-) real-time transmit datapath by setting the txenable or txrtenable bit in the command register.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-39 if transmitting other than the last fragment of a multi-fragment packet, the last bit in the descriptor must be set to 0; for the last fragment the last bit must be set to 1. to trigger an interrupt when the packet has been transmitted and transmission status has been committed to memory, set the interrupt bit in the descriptor control ?ld to 1. to have the hardware add a crc in the frame sequence control ?ld of this ethernet frame, set the crc bit in the descriptor. this should be done if the crc has not already been added by software. to enable automatic padding of small packets to the minimum required packet size, set the pad bit in the control ?ld of the descriptor to 1. in typical applications bits crc and pad are both set to 1. the device driver can set up interrupts using the intenable register to wait for a completion signal from the hardware, or it can periodically inspect (poll) the progress of transmission. it can also add new packets at the end of the descriptor fifo, while hardware consumes descriptors at the start of the fifo. the device driver can stop the transmit process by resetting command.txenable and command.txrtenable to 0. the transmission will not stop immediately; packets already being transmitted will be transmitted completely and the status will be committed to memory before deactivating the datapath. the status of the transmit datapath can be monitored by the device driver reading the txrtstatus/txstatus bits in the status register. as soon as the (non-) real-time transmit datapath is enabled and the corresponding tx(rt)consumeindex and tx(rt)produceindex are not equal (i.e. the hardware still must process packets from the descriptor fifo), the tx(rt)status bit in the status register will return to 1 (active). 5.4.3 tx(rt) dma manager reads tx(rt) descriptor arrays when the txenable bit (txrtenable bit for real-time traf?) is set, the tx dma manager reads the descriptors from memory using block transfers at the address determined by txdescriptor and txconsumeindex, or, for real-time traf?, at the address determined by txrtdescriptor and txrtconsumeindex. the block size of the block transfer is determined by the total number of descriptors owned by the hardware, which equals tx(rt)produceindex ?tx(rt)consumeindex. 5.4.4 tx(rt) dma manager transmits data after reading the descriptor, the transmit dma engine reads the associated packet data from memory and transmits the packet. after the transfer is complete, the tx dma manager writes status information back to the statusinfo and statustimestamp words of the status. the value of the tx(rt)consumeindex is only updated after status information has been committed to memory. the tx dma manager continues to transmit packets until the descriptor fifo is empty. if the transmit fifo is empty, the tx(rt)status bit in the status register will return to 0 (inactive). if the descriptor fifo is empty, the ethernet hardware will set the tx(rt)finishedint bit of the intstatus register. the transmit datapath will still be enabled. the tx dma manager inspects the last bit of the descriptor control ?ld when loading the descriptor. if the last bit is 0, this indicates that the packet consists of multiple fragments. the tx dma manager gathers all the fragments from the host memory visiting a string of packet descriptors. it appends the fragments, and sends
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-40 them out as one ethernet frame on the ethernet connection. when the tx dma manager ?ds a descriptor with the last bit in the control ?ld set to 1, this indicates the last fragment of the frame, and thus the end of the ethernet frame. 5.4.5 update consumeindex each time the tx(rt) dma manager commits a status word to memory, it completes the transmission of a descriptor. it increments the tx(rt)consumeindex (taking wrap around into account) to hand the descriptor back to the device driver software. software can re-use the descriptor for new transmissions after the hardware has handed it back. the device driver software can keep track of the progress of the dma manager by reading the tx(rt)consumeindex register to see how far along the transmit process is. when the tx descriptor fifos get emptied completely, the txconsumeindex and txrtconsumeindex retain their last value. 5.4.6 write transmission status after the packet has been transmitted over the (r)mii bus and the status has been committed to memory, the statusinfo and statustimestamp words of the packet descriptor are updated by the dma manager. if the descriptor is for the last fragment of a packet (or for the whole packet if there are no fragments), then error ?gs are set (on failure) or cleared (on success) depending on the success or failure of the packet transmission. error ?gs are error, latecollision, excessivecollision, underrun, excessivedefer, and defer. the collisioncount ?ld is set to the number of collisions the packet incurred, up to the retransmission maximum programmed in the collision window/retry register. the current time-stamp time is written to the statustimestamp ?ld. statuses for all but the last fragment in the packet will be written as soon as the data in the packet has been accepted by the tx(rt) dma manager. even if the descriptor is for a packet fragment other than the last fragment, the error ?gs and time-stamp are returned. if the mii interface detects a transmission error during transmission of a (multi-fragment) packet, the rest of the transmit data and all remaining fragments of the packet are still read. after an error, the remaining transmit data is discarded by the mii interface. in case of errors during transmission of a multi fragment packet, the error statuses will be repeated until the last fragment of the packet. statuses for all but the last fragment in the packet will be written as soon as the data in the packet has been accepted by the tx(rt) dma manager. the status for the last fragment in the packet will only be written after the transmission has completed on the ethernet connection. the status of the last packet transmission can also be inspected by reading the tsv0 and tsv1 registers. these registers do not report statuses on a fragment basis and do not store information of previously sent packets. 5.4.7 transmission error handling when an error occurs during the transmit process, the tx(rt) dma manager will report the error via the transmission status written in the status fifo and the intstatus interrupt status register.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-41 the transmission can generate several types of errors: latecollision, excessivecollision, excessivedefer, underrun, and nodescriptor. all have corresponding bits in the transmission status. on top of the separate bits in the status, bits for latecollision, excessivecollision, excessivedefer are ored together into the error bit of the status. errors are also propagated to the intstatus register: the tx(rt)error bit in the intstatus register is set in case of a latecollision, excessivecollision, excessivedefer, or nodescriptor error, while underrun errors are reported in the tx(rt)underrun bit of the intstatus register. underrun errors can have three causes: the next fragment in a multi fragment transmission is not available. this is a non fatal error. a nodescriptor status will be returned on the previous fragment and the intstatus.tx(rt)error bit will be set. the transmission fragment data is not available while the lan100 has already started sending the frame. this is a non fatal error. an underrun status will be returned on trans-fer and intstatus.tx(rt)error bit will be set. the ?w of transmission statuses stalls and a new status has to be written while a previous status still waits to be transferred. this is a fatal error which can only be resolved by soft resetting the hw. the ?st and second situations are non fatal and the device driver has to resend the frame or have upper sw layers resend the frame. in the third case the hw is in an unde?ed state and needs to be soft reset by setting the command.txreset bit. after reporting a latecollision, excessivecollision, excessivedefer or underrun error the transmission of the erroneous frame will be aborted, remaining transmission data and frame fragments will be dis-carded and transmission will continue with the next frame in the descriptor array. device drivers should catch the transmission errors and take action. 5.4.8 transmit triggers interrupts the transmit datapath can generate four different interrupt types: if the interrupt bit in the descriptor control ?ld is set, the tx dma will set the tx(rt)doneint bit in the intstatus register after sending the fragment and com- mitting the associated transmission status to memory. even if a descriptor (fragment) is not the last in a multi-fragment packet, the interrupt bit in the descriptor can be used to generate an interrupt. if the descriptor fifo is empty while the ethernet hardware is enabled, the hardware will set the tx(rt)finishedint bit of the intstatus register. in case memory does not provide transmission data at a suf?iently high band- width, the transmission may underrun, in which case the tx(rt)underrun bit will be set in the intstatus register. another cause for underrun is if the trans- mission status interface stalls. this is a fatal error which requires a softreset of the transmission queue. in the event of a transmission error (such as latecollision, excessivecollision or excessivedefer) or if the device driver provided initial fragments but did not provide the rest of the fragments (nodescriptor) or in case of a non fatal over- run the hardware will set the tx(rt)errorint bit of the intstatus register.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-42 all of the above interrupts can be enabled and disabled by setting or resetting the corresponding bits in the intenable register. enabling or disabling interrupts does not affect the intstatus register contents, only the propagation of the interrupt status to the cpu. the interrupts, either of individual packets or of the whole list, are a good means of communication between the dma manager and the device driver, triggering the device driver to inspect the status words of descriptors that have been processed. 5.4.9 transmit example figure 6 illustrates the transmit process with a packet header of 8 bytes and a packet payload of 12 bytes. after reset, the values of the dma registers will be zero. during initialization, the device driver will allocate the descriptor and status array in memory. in this example, an array of four descriptors is allocated; the array is 4x4x4 bytes and aligned on a 4-byte address boundary. since the number of descriptors should match the number of statuses, the status array consists of four elements; the array is 4x2x4 bytes and aligned on an 8-byte address boundary. the device driver writes the base address of the descriptor array (0xfeedb0ec) in the tx(rt)descriptor register and the base address of the status array (0xfeedb1f8) in the tx(rt)status register. the device figure 6: transmit example memory and registers tx(rt)status 0xfeedb1f8 packet 0xfeedb314 control 0 07 time-stamp pad descriptor 0 tx(rt)descriptor 0xfeedb0ec 0xfeedb0ec 0xfeedb0f8 0xfeedb118 0xfeedb0fc 0xfeedb008 descriptor array 0xfeedb10c 0xfeedb11c 0xfeedb128 0xfeedb314 packet 0 header (8 bytes) 0xfeedb411 0xfeedb41c packet 0 payload (12 bytes) 0xfeedb32b 0xfeedb1f8 statusinfo statustimestamp status 0 0xfeedb200 0xfeedb208 0xfeedb210 packet 0xfeedb411 control 0 07 time-stamp pad descriptor 1 packet 0xfeedb419 control 0 07 time-stamp pad descriptor 2 packet 0xfeedb324 control 0 07 time-stamp pad descriptor 3 packet 1 header (8 bytes) 0xfeedb324 tx(rt)consumeindex tx(rt)produceindex tx(rt)descriptorindex statusinfo statustimestamp statusinfo statustimestamp statusinfo statustimestamp status 1 status 2 status 3 status array 0xfeedb31b descriptor array fifo fragment buffers status array fifo
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-43 driver writes the number of descriptors and statuses (4) in the tx(rt)descriptornumber register. the descriptors and statuses in the arrays need not be initialized, yet. initialization may already enable the transmit datapath by setting the tx(rt)enable bit in the command register. in case the transmit datapath is enabled while there are no further packets to send, the tx(rt)finishedint interrupt ?g will be set. to reduce the processor interrupt load, some interrupts can be disabled by setting the relevant bits in the intenable register. now suppose application software wants to transmit a packet of 12 bytes using a tcp/ip protocol (though in realistic applications, packets will be larger than 12 bytes). the tcp/ip stack will add a header to the packet. because the lan100 can perform scatter/gather dma, the packet header need not be located in memory at the beginning of the payload data. the device driver can program a tx gather dma operation to collect header and payload data. to do so, the device driver will program the ?st descriptor to point at the packet header; the last ?g in the descriptor will be set to 0 to indicate a multi-fragment transmission. the device driver will program the next descriptor to point at the actual payload data. the maximum size of a payload buffer is 2kb, so a single descriptor suf?es to describe the payload buffer. for the sake of the example though, the payload is distributed across two descriptors. after the ?st descriptor in the array describing the header, the second descriptor in the descriptor array describes the initial 8 bytes of the payload; the third descriptor in the array describes the remaining 4 bytes of the packet. in the third descriptor the last bit in the control word is set to 1 to indicate it is the last descriptor in the packet. in this example the interrupt bit in the descriptor control ?ld is set in the last fragment of the packet to trigger an interrupt after the transmission completed. the size ?ld in the descriptors control word is set to the number of bytes in the fragment buffer, ? encoded. note that in more realistic applications, the payload would be split across multiple descriptors only if it is more than 2kb. also note that transmission payload data is forwarded to the hardware without the device driver having to copy it (zero copy device driver). after setting up the descriptors for the transaction, the device driver increments the tx(rt)produceindex register by 3, since three descriptors have been programmed. if the transmit datapath was not enabled during initialization the device driver must enable the datapath now. if the transmit datapath is enabled, the lan100 will start transmitting the packet as soon as it detects the tx(rt)produceindex is not equal to tx(rt)consumeindex. the tx(rt) dma will start reading the descriptors from memory with the base address from the tx(rt)descriptor register and a block size of 3 descriptors * 4 words per descriptor = 12 . the memory system will return the descriptors and the lan100 will accept them one by one while issuing read commands for reading the transmit data fragments. the commands will have the address from the packet ?ld in the descriptor and a block size equal to the size ?ld in the descriptor. as soon as transmission read data is returned from memory, the lan100 will try to start transmission on the ethernet connection via the (r)mii interface.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-44 while issuing the descriptor read commands, the tx(rt) dma manager also begins to write the transmission status. the status write command address will be taken from the tx(rt)status register; the block size will be 3 statuse s * 1 double words = 3 . after transmitting each fragment of the packet, the tx(rt) dma will write the status of the fragments transmission. statuses for all but the last fragment in the packet will be written as soon as the data in the packet has been accepted by the tx(rt) dma manager. the status for the last fragment in the packet will only be written after the transmission has completed on the ethernet connection. the tx(rt) dma manager checks if status write data has been committed to memory. only then are the tx(rt)consumeindex updated and the interrupt ?gs forwarded to the intstatus register. the lan100 tags transmit statuses continuously but does not necessarily tag every status individually. since the interrupt bit in the descriptor of the last fragment is set, after committing status of the last fragment to memory, the lan100 will trigger a tx(rt)doneint interrupt which triggers the device driver to inspect the status information. in this example, the device driver cannot add new descriptors as long as the lan100 has incremented the tx(rt)consumeindex because the descriptor array is full (even though one descriptor is not programmed yet (see section 5.2.4 on page 23- 35 ). only after committing the status for the ?st fragment to memory and updating the tx(rt)consumeindex to 1 can the device driver program the next (the fourth) descriptor. the fourth descriptor can be programmed before completely transmitting the ?st packet. in this example the hardware adds the crc. if the device driver software adds the crc, the crc trailer can be considered another packet fragment which can be added by doing another gather dma operation.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-45 figure 7 depicts the memory transactions and the transactions on the mii interface for this example. each byte transferred from memory is transmitted across the mii interface as a byte, and the mii interface hardware adds the preamble, frame delimiter leader, and the crc trailer, if hardware crc is enabled. once transmission on the mii interface commences, the transmission cannot be interrupted without generating an underrun error, which is why descriptors and data read commands are issued as soon as possible and are pipelined. in 10mb/s and 100mb/s mode, the output signals look similar, but in 10mb/s mode, the transmit clock is scaled down by a factor 10. in case an rmii phy is connected, the data communication between the mii interface and the phy is communicated at half the data-width and twice the clock frequency (50 mhz). in figure 7 , the frequency of the mii transmit data signal will be doubled in the 100mb/s mode. in 10mb/s mode, data will only be transmitted once every 10 clock cycles (an clock gate disables the 50mhz clock for the intervening nine cycles). 5.5 receive process this section outlines the receive process including the activities in the device driver software. figure 7: transmit example waves mmio cmd. mmio write data descriptor read cmd. descriptor read data descriptor read last data read command data read data data read last mii transmit data write status cmd. status write data write status last write status tag status write tag ack. tx(rt)produceindex tx(rt)consumeindex mmio write produce index 3 descriptor read data returned issue data read issue data returned start transmission preamble issue descriptor read and status write commands write ?st fragment status tag status crc end transmission wait for tag acknowledge update consume register 1 2 3 3 0 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-46 5.5.1 device driver sets up descriptors after initializing the receive descriptor and status arrays to receive packets from the ethernet connection (as de?ed in section 5.3 ), the receive datapath should be enabled via the mac1 register and the control register. during initialization, each packet pointer in the descriptors is set to point to a data fragment buffer. the size of the buffer is stored in the size bits of the control ?ld of the descriptor. additionally the control ?ld in the descriptor has an interrupt bit which allows generation of an interrupt after a fragment buffer has been ?led and its status has been committed to memory. after the receive datapath is initialized and enabled, all descriptors are owned by the receive hardware and should not be modi?d by the software unless hardware hands over the descriptor by incrementing the rxproduceindex indicating a packet has been received. the device driver is allowed to modify the descriptors after a (soft) reset of the receive datapath. 5.5.2 rx dma manager reads rx descriptor arrays when the rxenable bit in the command register is set, the rx dma manager reads descriptors from memory with block transfers at the address determined by rxdescriptor and rxproduceindex. the lan100 will start reading descriptors even before actual receive data arrives on the mii interface (called descriptor prefetching ). the block size of the descriptor read block transfer is determined by the total number of descriptors owned by the hardware: rxconsumeindex ?rxproduceindex ?1. transferring blocks of descriptors maximizes prefetching and minimizes memory loading. read data returned from the descriptor read operation is consumed per descriptor, and only if needed. 5.5.3 rx dma manager receives data after reading the descriptor, the receive dma engine waits for the mii interface to return receive data that pass the receive ?tering process. receive packets that do not match the ?tering criteria are not passed to memory. for more information on ?tering refer to section 5.12 . once a packet passes the receive ?ter, the data is written in the descriptors fragment buffer in memory. the rx dma manager does not write beyond the size of the buffer. in case a packet is received that is larger than a descriptors fragment buffer, the packet will be written to multiple fragment buffers of consecutive descriptors. if a multi-fragment packet is received, all but the last fragment in the packet will return a status word with the last bit set to 0. only on the last fragment of a packet is the last bit set in the status word. if a fragment buffer is the last of a packet, the buffer may not be ?led completely. the ?st receive data of the next packet will be written to the next descriptors fragment buffer. after receiving a fragment, the rx dma manager writes status information back to the statusinfo and statustimestamp ?lds of the status word.the lan100 writes the ?l level of a descriptors fragment buffer in the entrylevel ?ld of the status word. the value of the rxproduceindex is only updated after the fragment data and the fragment status information has been committed to memory. this is checked by sensing the write acknowledge signal returned from memory. the rx dma manager continues to receive packets until the descriptor fifo is full. if it becomes full, the
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-47 ethernet hardware will set the rxfinishedint bit of the intstatus register. the receive datapath will still be enabled. if the receive fifo is full, any new receive data will generate an over?w error and interrupt the cpu. 5.5.4 update produceindex each time the rx dma manager commits fragment data and the associated status word to memory, it completes the reception of a descriptor and it increments the rxproduceindex (taking wrap-around into account) and hands the descriptor back to the device driver software. software can re-use the descriptor for new reception by handing it back to hardware when the receive data has been processed. the device driver software can keep track of the progress of the dma manager by reading the rxproduceindex register to see how far along the receive process is. when the rx descriptor fifo is emptied completely, the rxproduceindex retains its last value. 5.5.5 write reception status after the packet has been received from the mii interface, the statusinfo and statustimestamp words of the packet descriptor are updated by the dma manager. if the descriptor is for the last fragment of a packet (or for the whole packet if there are no fragments), then, depending on the success or failure of packet reception, error ?gs (error, nodescriptor, overrun, alignmenterror, rangeerror, lengtherror, symbolerror, and crcerror) are set in the status word. the entrylevel ?ld is set to the number of bytes actually written to the fragment buffer, ?-encoded. for fragments that are not the last in the packet, the entrylevel will match the size of the buffer. the current time-stamp time is written to the statustimestamp ?ld. if the reception reports an error, any remaining data in the receive packet is discarded and the last bit will be set in the receive status ?ld so the error ?gs in all but the last fragment of a packet will always be 0. the status of the last receive packet can also be inspected by reading the rsv register. the register does not report statuses on a fragment basis and does not store information about previously received packets. 5.5.6 reception error handling when an error occurs during the receive process, the rx dma manager will report the error via the receive status word written in the status fifo and the intstatus interrupt status register. the receive process can generate several types of errors, including: alignmenterror, rangeerror, lengtherror, symbolerror, crcerror, overrun, and nodescriptor. all have corresponding bits in the receive status word. in addition to this, alignmenterror, rangeerror, lengtherror, symbolerror, crcerror are ored together into the error bit of the status word. errors are also propagated to the intstatus register. the rxerror bit in the intstatus register is set in case of a alignmenterror, rangeerror, lengtherror, symbolerror, crcerror, and nodescriptor error; fatal overrun errors are report in the rxoverrun bit of the intstatus register. on fatal overrun errors the rx datapath needs to be soft rest by setting the command.rxreset bit. overrun errors can have three causes:
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-48 in case of a multi-fragment reception the next descriptor may be missing. in this case the nodescriptor ?ld is set in the status word of the previous descriptor and the rxerror in the intstatus register is set. this error is non fatal. the data ?w on the receiver data interface stalls corrupting the packet. in this case the overrun bit in the status word is set and the rxerror bit in the intstatus register is set. this error is non fatal. the ?w of transmission statuses stalls and a new status has to be written while a previous status still waits to be transferred. this error will corrupt the hw state and requires the hw to be soft reset. the error is detected and sets the overrun bit in the intstatus register. the ?st overrun situation will result in an incomplete frame with a nodescriptor status and the intstatus. rxerror bit set. sw should discard the partially received frame. in the second overrun situation the frame data will be corrupt which results in the overrun status bit being set in the status word while the interror interrupt bit is set. in the third case receive errors cannot be reported in the receiver status arrays which corrupts the hw state; the errors will still be reported in the intstatus register s overun bit and the command.rxreset bit should be used to soft reset the hw. device drivers should catch the receive errors and take action. 5.5.7 receive triggers interrupts the receive datapath can generate four different interrupt types: if the interrupt bit in the descriptor control ?ld is set, the rx dma will set the rxdoneint bit in the intstatus register after receiving a fragment and committing the associated data and status to memory. even if a descriptor (fragment) is not the last in a multi-fragment packet, the interrupt bit in the descriptor can be used to generate an interrupt. if the descriptor fifo is full while the ethernet hardware is enabled, the hardware will set the rxfinishedint bit of the intstatus register. if memory does not consume receive data at a suf?iently high bandwidth, the receive process may overrun, in which case the rxoverrun bit will be set in the intstatus register. in case of a receive error (alignmenterror, rangeerror, lengtherror, symbolerror, crcerror) or a multi fragment frame where the device driver did provide descriptors for the initial fragments but did not provide the descriptors for the rest of the fragments or if a non fatal data overrun occured the hardware will set the rxerrorint bit of the intstatus register. all of the above interrupts can be enabled and disabled by setting or resetting the corresponding bits in the intenable register. enabling or disabling does not affect the intstatus register contents, only the propagation of the interrupt status to the cpu. the interrupts, either of individual packets or of the whole list, are a good means of communication between the dma manager and the device driver, triggering the device driver to inspect the status words of descriptors that have been processed.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-49 5.5.8 device driver processes receive data the device driver can be signaled to read the descriptors that have been handed over to it by the hardware by observing status word ?gs (for example, rxdoneint), receiving interrupts, or polling for the case where rxproduceindex rxconsumeindex is not 0. the device driver should inspect the status words in the status fifo to check for multi-fragment packets and receive errors. the device driver can forward receive data and status to higher-level software layers. after data and status are processed, the descriptors, status words and data buffers may be recycled and handed back to hardware by incrementing rxconsumeindex. 5.5.9 receive example figure figure 8 illustrates the receive process in an example receiving a packet of 16 bytes. after reset, the values of the lan100 dma registers will be zero. during initialization, the device driver must allocate the descriptor and status array in memory. in this example, an array of four descriptors is allocated. the array is 4x2x4 bytes, and is aligned on a 4-byte address boundary. since the number of descriptors should match the number of status words, the status array consists of four elements. the status array is 4x2x4 bytes, and is aligned on an 8-byte address boundary. the device driver writes the base address of the descriptor array (0xfeedb0ec) to the rxdescriptor register, and the base address of the status array (0xfeedb1f8) to the rxstatus figure 8: receive example memory and registers rxdescriptor 0xfeedb0ec rxstatus 0xfeedb1f8 rxproduceindex rxconsumeindex rxdescriptornumber 3 packet 0xfeedb409 control 17 descriptor 0 packet 0xfeedb4111 control 17 descriptor 1 packet 0xfeedb419 control 17 descriptor 2 packet 0xfeedb325 control 17 descriptor 3 0xfeedb0ec 0xfeedb0f0 0xfeedb0f8 0xfeedb0f4 0xfeedb1fc 0xfeedb200 0xfeedb204 0xfeedb208 fragment 0 buffer (8 bytes) 0xfeedb409 0xfeedb411 fragment 1 buffer (8 bytes) 0xfeedb411 0xfeedb418 fragment 2 buffer (8 bytes) 0xfeedb419 0xfeedb420 fragment 3 buffer (8 bytes) 0xfeedb325 0xfeedb32c statusinfo 7 statustimestamp status 0 0xfeedb1f8 0xfeedb200 0xfeedb208 0xfeedb210 statusinfo 7 statustimestamp status 1 statusinfo 3 statustimestamp status 2 statusinfo statustimestamp status 3 descriptor array status array descriptor array fifo fragments status array fifo
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-50 register. the device driver writes the number of descriptors and status words (4) in the rxdescriptornumber register. the descriptors and status words in the arrays need not be initialized, yet. after allocating the descriptors, a fragment buffer must be allocated for each of the descriptors. each fragment buffer can be between 0 and 2k bytes. the base address of the fragment buffer is stored in the packet ?ld of the descriptors. the number of bytes in the fragment buffer is stored in the size ?ld of the descriptor control word. the interrupt ?ld in the control word of the descriptor can be set to generate an interrupt as soon as the descriptor has been ?led by the receive process. in this example the fragment buffers are 8 bytes, so the value of the size ?ld in the control word of the descriptor is set to 7. note that in this example the fragment buffers are actually a continuous memory space; even when a packet is distributed over multiple fragments, most of the time it will be in a linear, continuous memory space; only when the descriptors wrap at the end of the descriptor array will the packet not be in a continuous memory space. the device driver should enable the receive process by writin ga1tothe rxenable bit of the command register after which the mac must be enabled by writing a 1 to the receive_enable bit of the mac1 con?uration register. the lan100 will now start receiving ethernet packets. to reduce the processor interrupt load, some interrupts can be disabled by setting the relevant bits in the intenable register. after the rx dma manager is enabled, it will start reading descriptors from memory. in this example, the number of descriptors is 4. initially the rxproduceindex and rxconsumeindex are 0. since the descriptor array is considered full if rxproduceindex == rxconsumeindex ?1, the rx dma manager can only read (rxconsumeindex rxproduceindex 1) = 3 descriptors (note the index wrapping). the rx dma manager reads the descriptors from memory; the start address will be 0xfeedbdec (rxdescriptor) and the block size will be 3 descriptors * 2 words per descriptor ? = 5 (because the block size is ? encoded). while descriptor read commands the rx dma manager also sets itself up to write the transmission status. the status write command address will be taken from the rxstatus register; the block size value will be 3 status words * 1 double word ? = 2 (because block size is ? encoded). after enabling the receive function in the lan100, it will start receiving data from the mii interface starting at the next packet. that is, if the receive function is enabled while the mii interface is in the middle of a packet, that packet will be discarded and reception will start with the next packet. the lan100 will strip the preamble and start-of-frame delimiter from the packet. if the packet passes the receive ?tering, the rx dma manager will start writing the packet to the ?st fragment buffer. for example, if the incomming packet is 19 bytes, then it will be distributed over three fragment buffers. after writing the initial 8 bytes in the ?st fragment buffer, the status for the ?st fragment buffer will be written and the rx dma will continue ?ling the second fragment buffer. since this is a multi-fragment receive, the status word of the ?st fragment will have a 0 for the last bit in the statusinfo word; the entrylevel ?ld will be set to 7 (for a value of 8, because of ? encoding). after writing the 8 bytes in the second fragment, the rx dma will continue writing the third fragment. the status of the second fragment will be like the status of the ?st fragment: last = 0, entrylevel = 7. after writing the three bytes in the third fragment buffer, the end of the packet has
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-51 been reached and the status of the third fragment is written. the third fragments status word will have the last bit set to 1 and the entrylevel equal to 2 (for a value of 3, because of ? encoding). the next packet received from the mii interface will be written to the fourth fragment buffer, therefore ?e bytes of the third buffer will be unused. the rx dma manager checks to make sure receive data and status data have been committed to memory. only if memory acknowledges that the data has been committed to memory will the rxproduceindex be updated and the interrupt ?gs be forwarded to the intstatus register. the lan100 tags receive data and statuses continuously but does not necessarily tag every data and every status individually. after committing status of the fragments to memory the lan100 will trigger a rxdoneint interrupt, which triggers the device driver to inspect the status information. in this example all descriptors have the interrupt bit set in the control word, so all descriptors will generate an interrupt after committing data and status to memory. in this example, the receive function of the lan100 cannot read new descriptors as long as the device driver does not increment the rxconsumeindex because the descriptor array is full (even though one descriptor is not programmed yet, see section 5.2.4 on page 23- 35 ). only after the device driver has forwarded the receive data to application software and after the device driver has updated the rxconsumeindex by incrementing it by the number of received fragments (3 in this case) can the lan100 continue reading descriptors and receive data.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-52 figure 9 illustrates what the memory transactions and the mii interface transactions for this example could look like. each pair of nibbles on the mii interface is transferred to memory as a byte after being delayed by 128 or 136 cycles for ?tering by the receive ?ter and buffer modules. the lan100 removes the preamble, frame start delimiter, and crc from the mii data and checks the crc. to limit the probability of nodescriptor errors, the lan100 buffers two descriptors. after the write to memory is acknowledged for data and status, the rxproduceindex is updated. the software device driver should now process the receive data, after which the it should update the rxconsumeindex. for 100 mb/s and 10 mb/s the waveforms look identical except for frequency: in 10 mb/s mode the mii receive input clock is 2.5 mhz and in 100 mb/s mode the input clock is 25 mhz. in case an rmii phy is connected to the mii interface, the data communication between the lan100 and the phy takes place at half the data-width and twice the clock frequency (50 mhz). in figure 9 , the signal marked ?ii receive data?will have doubled frequency for the 100mb/s mode. in 10mb/s mode, data will only be transmitted once every 10 clock cycles; an external clock gate disables the 50mhz clock for the 9 cycles. figure 9: receive example waves mmio cmd mmio write data descr. read cmd. descr. read data descr. read last mii receive data data write trans/cmd data write cmd/data data request ack. data receive ack. status write cmd. status write data status write last status request ack. status receive ack. rxproduceindex rxconsumeindex mmio write enable rx dma buffer two descriptors packet already underway when enabled, discard for receive preamble 128-136 cycles delay due to ?tering first data in packet crc status written tag status and data both tags acknowledged, update produceindex, set interrupts 0 0 1 2 3 3 mmio write, update rxconsumeindex last data in fragment, write fragment status
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-53 5.6 transmission retry if a packet collision occurs on the ethernet, it usually takes place during the collision window spanning the ?st 64 bytes of a packet. if collision is detected, the lan100 will retry the transmission. for this reason, the ?st 64 bytes of a packet are buffered by the lan100 so that it can be used during the retry. a transmission retry within the ?st 64 bytes in a packet is fully transparent to the application and device driver software. when a collision occurs outside of the 64-byte collision window, a latecollision error is triggered and the transmission is aborted. after a latecollision error, the remaining data in the transmit packet is discarded. the lan100 sets the error and latecollision bits in the packets status ?lds. the tx(rt)error bit in the intstatus register is set. if the corresponding bit in the intenable register is set, the tx(rt)error bit in the intstatus register will be propagated to the cpu. the device driver software should catch the interrupt and take appropriate actions. the retransmission_maximum ?ld of the clrt register can be used to con?ure the maximum number of retries before aborting the transmission. 5.7 time-stamps the lan100 has an internal time-stamp counter register, readable by software via the globaltimestamp register. after reset, the time-stamp counter is 0. every clock tick of the time-stamp clock, the value of the time-stamp counter is incremented by 1. after 2 32 ? clock ticks, the counter wraps back to 0. the time-stamp counter is only reset by asserting a hard reset. since the time-stamp is 32 bits in length, the maximum time that can be counted is (2 32 ?) * t clk where t clk is the period of the time-stamp clock. for a 100 mhz time-stamp clock this corresponds to a 42 second period. the actual frequency of the time-stamp clock may depend upon the software stack. the maximum frequency supported by the hardware is 200 mhz. the value of the time-stamp counter is copied in the time-stamp ?ld of the status word returned with transmit and receive fragments and packets. the device driver is able to determine the exact moment of transmission, reception and latencies using the time-stamp from the status word and the actual time-stamp value in the globaltimestamp register. 5.8 transmission modes 5.8.1 overview the lan100 hardware has two transmission datapaths: tx and txrt. these transmission datapaths can be switched in two modes: real-time/non-real-time mode: in this mode, the txrt transmission datapath handles real-time transmissions, and the tx datapath handles non-real-time transmissions.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-54 quality of service (qos) mode: in this mode, the txrt transmission datapath handles low priority transmission, while the tx datapath handles high priority transmissions. each transmit data-path has its own associated descriptor and status array in memory and its own dma manager for transferring data to and from memory. an arbiter internal to the lan100 decides which of the transmit dma managers should be allowed to transmit a packet, based on the mode of operation, the time-stamp and the priority. the modes can be selected by the device driver by programming the qosenable bit in the command register. setting the bit to 0 selects real-time/non-real-time mode; setting the bit to 1 selects qos mode. the device driver should con?ure one of the modes during initialization of the lan100. on a simple network stack, qos mode may be used by creating devices named ?th0?and ?th1? one of which maps to the high priority transmit datapath while the other maps to the low priority transmit datapath. in order to use the real-time/non-real-time mode, the network stack should have some support for time-stamps. 5.8.2 real-time/non-real-time transmission mode in real-time/non-real-time mode, that is, when the qosenable bit of the command register is set to 0, the tx transmit datapath transmits non-real-time packets while the txrt datapath transmits real-time packets. transmit time-stamps allow software to specify the time when the packet should be transmitted for each packet in the txrt descriptor array. a transmit time-stamp value is included by software in the time-stamp ?ld of real-time transmit packet descriptors. these ?lds are ignored in the non-real-time descriptors or in qos mode. there are two transmit descriptors arrays, one for real-time traf? with transmit time-stamps and one for non-real-time traf? without transmit time-stamps. each descriptor array is handled in sequential order by the associated dma manager (tx and txrt). packets in the real-time descriptor array have priority over packets in the non-real-time array as soon as the time-stamp has supplied. packets in the real-time array must be ordered by software in ascending time-stamp value order. the transmit arbiter will inspect the time-stamp of a real-time packet and pass it for transmission as soon as the globaltimestamp counter register exceeds the time-stamp located in the time-stamp ?ld in the descriptor of the packets ?st fragment. while the packet in the txrt dma is waiting for the globaltimestamp to exceed the time-stamp in the current packet, the arbiter will permit the tx dma to transmit packets. care must be taken that the scheduling of real-time packets does not completely lock out non-real-time packets from gaining access to the ethernet connection. also, when multiple real-time packets are scheduled, there must be enough difference between their time-stamp values to have time to actually complete the packet transmissions. when a packet misses its time-stamp moment, that is, when the current value of the time-stamp generator is larger than the time-stamp value at the moment when a descriptor is read by the tx dma manager, then the packet will be sent as soon as possible after that moment. however, since time-stamps will eventually be reused
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-55 (because the globaltimestamp counter wraps around 0), packets with time-stamps that are late are only sent out when the difference between the time-stamp of the packet and the local time-stamp of the time-stamp generator is less than half the total time-stamp range , that is, less than 2 31 . if the difference is more than 2 31 , then the packet will not be transmitted, and the packet and all other packets in the real-time descriptor list must wait until the value of the time-stamp generator wraps around to its time-stamp value, or until software removes such a ?tuck packet by soft resetting the transmit datapath. the register blockzone can be used to specify a time period before a transmit time-stamp value during which no new transmission of non-real-time packets can be started. this can help to free up the ethernet wire for the impending real-time packet. the unit of time of the blockzone register is equal to the unit of time of the time-stamp generator. in pseudo-code, the real-time/non-real-time arbitration proceeds as follows: diff[31:0] = globaltimestamp[31:0] - txrtdescriptor.timestamp[31:0]; bs[31:0] = globaltimestamp[31:0] + blockzone[31:0] - txrtdescriptor.timestamp[31:0] if (!diff[31]) // is globaltimestamp > descriptor time-stamp? // true // if possible, issue txrt packet else if (!bs) // we are in the blockzone, so do not issue else // if possible, issue tx packet if a non-real-time packet is still occupying the transmit logic when the time-stamp moment of a real-time packet is reached, then the packet will be transmitted as soon as the non-real-time packet has ?ished. when the value in blockzone is 0, the blockzone mechanism is disabled. apart from using time-stamps for real-time transmission, the lan100 also reports back to software the actual moment that packets are received or transmitted, as speci?d in section 5.7 .
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-56 real-time/non-real-time example figure 10 shows an example of real-time and non-real-time traf?. in this example initially both transmission queues have three descriptors; the ?st packet in the real-time queue must be transmitted at time-stamp 90, the second packet must be transmitted at time-stamp 110, and the third packet must be transmitted at time-stamp 260. the packets in the non-real-time queue will be transmitted as soon as possible. in this example the blockzone register is set to 30 time-stamp cycles. after the device driver has set up the descriptors at time-stamp 50, the lan100 starts transmission. the initial real-time packet need not be transmitted yet, so a packet from the non-real-time queue is transmitted ?st. during transmission of the non-real-time packet, the time-stamp of the ?st real-time packet expires, and the real-time packet will be transmitted as soon as transmission of the non-real-time packet completes. after transmitting the ?st real-time packet, the time-stamp of the second real-time packet expires, and the transmission of the second real-time packet commences as soon as the ?st real-time packet completes transmission. after sending the second real-time packet, no new packets are sent out, since the time-stamp is within the range of the block zone of the third real-time packet. as soon as the time-stamp counter passes the packets time-stamp, the third real-time packet is transmitted. after completing transmission of the third real-time packet, the real-time queue is empty, and the remaining non-real-time packets are transmitted as soon as possible. figure 10: real-time/non-real-time transmit example txrt descriptors tx descriptors block zone expired lan pr t1@90, pr t2@110, prt3@260 pr t2@110, prt3@260 prt3@260 p1 p2 p3 p2 p3 p3 p1 prt1 prt2 prt3 p2 p3 tx clk cycles 0 50 100 150 200 250 300 350 400 450 500
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-57 5.8.3 quality-of-service transmission mode the two transmit descriptor/status arrays and datapaths can also be used to implement a generic quality-of-service (qos) mechanism for transmit packets. the qos mechanism distinguishes two priority queues: a queue with low priority and a queue with high priority. the tx descriptor fifo (using txdescriptor and txstatus) and tx dma manager implement the high-priority queue and the txrt descriptor fifo (using txrtdescriptor and txrtstatus) and txrt dma manager implement the low-priority queue. to implement qos, software should enter transmit packets that have a high quality of service requirements into the tx (high-priority) descriptor array, while other packets should be entered into the txrt (low-priority) descriptor array. if there are any packets in the high priority queue, they are sent out ?st before any packets that are waiting in the low-priority queue. packets in the low-priority queue are only sent if the high-priority queue is empty. to prevent starvation of packets in the low priority queue, the qostimeout register de?es the maximum number of transmit clock cycles that low-priority packet must wait at the head of the low-priority queue. an internal time-out counter starts counting transmit clock cycles, starting from 0, as soon as a low-priority packet reaches the transmission arbiter. if the low-priority packet is still waiting to be transmitted when the counter reaches the qostimeout registers value, then the arbiter will promote the priority of only that one low-priority packet over the high priority queue. after sending the low-priority packet, the low-priority queue will be set back to the low priority. the waiting time of a packet in the low-priority queue can be larger than the qostimeout registers value if it has to wait to reach the head of the queue. to enable the qos mechanism, set bit enableqos bit in the command register to 1. when the qos mechanism is active, the time-stamp word in the tx and txrt descriptors is ignored, and the blockzone register is disabled. the descriptor format is still the same.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-58 qos example figure 11 shows an example of qos transmissions. in this example, the low-priority queue has two packets and the high priority queue contains three packets. the qostimeout register is set to 70 transmit clock cycles. initially the lan100 will start transmitting packets from the high-priority queue. as soon as the qostimeout expires, the lan100 will send out a single packet from the low-priority queue, after which it continues transmitting packets from the high-priority queue. as soon as the remaining packet in the high-priority queue has been transmitted and the high-priority queue is empty, the lan100 will continue transmitting packets from the low-priority queue. 5.9 duplex modes the lan100 can operate in full-duplex and half-duplex mode. half- or full-duplex mode must be con?ured by the device driver software during initialization of the lan100. for full duplex, the fullduplex bit of the command register must be set to 1 and the full_duplex bit of the mac2 con?uration register must be set to 1. for half duplex, the same bits must be set to 0. figure 11: qos transmission example 0 50 100 150 200 250 300 350 400 450 500 tx clk cycles txrt descriptors (low prio.) tx descriptors (high prio.) qostimeoutcnt lan pi1, pi2 ph1, ph2, ph3 ph2, ph3 pi2 ph3 ph1 ph2 pi1 ph3 pi2
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-59 5.10 ieee 802.3/clause 31 flow control 5.10.1 overview for full-duplex connections, the lan100 supports ieee 802.3/clause 31 ?w control using pause frames. this type of ?w control may be used in full-duplex point-to-point connections. flow control allows a receiver to stall a transmitter, for example, when the receive buffers are (almost) full. for this purpose the receiving side sends a pause frame to the transmitting side. pause frames use units of 512 bit-slot times, corresponding to 128 times the ratio of receive clock to transmit clock cycles. 5.10.2 receive flow control in full-duplex mode the lan100 will suspend its transmissions when it receives a pause control frame. receive ?w control is initiated by the receiving side of the lan100. it is enabled using the mac1 con?uration register by setting the rx_ flow_control bit to 1. if the rx_flow_control bit is zero, then the lan100 ignores received pause control frames. when a pause frame is received on the rx side of the lan100, transmission on the tx side will be interrupted after the currently transmitting frame has completed for an amount of time as indicated in the received pause frame. the transmit datapath of the lan100 will stop transmitting data for the number of 512-bit slot times encoded in the pause-timer ?ld of the received pause control frame. by default, the received pause control frames are not forwarded to the device driver. to forward the received ?w-control frames to the device driver, set the pass_all_ receive_frames bit in the mac1 con?uration register. 5.10.3 transmit flow control if device drivers need to stall the receive data, for example, because software buffers are full, the lan100 can transmit pause control frames. transmit ?w control must be initiated by the device driver software; there is no ieee 802.3/31 ?w control initiated by the hardware, such as the dma managers. with software ?w control, the device driver can detect when the process of receiving packets must be interrupted by sending out tx pause frames. note that due to ethernet delays, a few packets can still be received before the ?w control takes effect and the receive stream stops. transmit ?w control is activated by writing 1 to the txflowcontrol bit of the command register. when the ethernet module operates in full-duplex mode, this will result in transmission of ieee 802.3/31 pause frames. the ?w control continues until a 0 is written to txflowcontrol bit of the command register. if the mac is operating in full-duplex mode, then setting the txflowcontrol bit of the command register will start a pause-frame transmission. the value inserted into the pause-timer value ?ld of transmitted pause frames is programmed via the pausetimer[15:0] bits in the flowcontrolcounter register. when the txflowcontrol bit is deasserted, another pause frame having a pause-timer value of 0x0000 is automatically sent to abort ?w control and resume transmission.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-60 when the ?w control must last a long time, a sequence of pause frames must be transmitted. this is supported with a mirror counter mechanism. to enable mirror counting, write a non-zero value to the mirrorcounter[15:0] bits in the flowcontrolcounter register. when the txflowcontrol bit is asserted, a pause frame is transmitted. after sending the pause frame, an internal mirror counter is initialized to zero. the internal mirror counter starts incrementing once every 512 bit-slot times. when the internal mirror counter reaches the mirrorcounter value, another pause frame is transmitted with a pause-timer value equal to the pausetimer ?ld from the flowcontrolcounter register. the internal mirror counter is reset to zero and the counter restarts. the register mirrorcounter[15:0] is usually set to a smaller value than the pausetimer[15:0] register to ensure an early expiration of the mirror counter so as to be able to send a new pause frame before the transmission on the other side can resume. by continuing to send pause frames before the transmitting side ?ishes counting the pause timer, the pause can be extended as long as txflowcontrol is asserted. this continues until txflowcontrol is deasserted, when a ?al pause frame with a pause-timer value of 0x0000 is automatically sent to abort ?w control and resume transmission. to disable the mirror counter mechanism, write the value 0 to mirrorcounter ?ld in the flowcontrolcounter register. when using the mirror counter mechanism to account for time-of-?ght delays, frame transmission time, queuing delays, crystal frequency tolerances, and response time delays, the mirrorcounter should be programmed conservatively, typically at about 80% of the pausetimer value. if the software device driver sets the mirrorcounter ?ld of the flowcontrolcounter register to zero, the lan100 will only send one pause control frame. after sending the pause frame, an internal pause counter is initialized to zero; the internal pause counter is incremented by one every 512 bit-slot times. once the internal pause counter reaches the value of the pausetimer register, the lan100 will reset the txflowcontrol bit in the command register. the software device driver can poll the txflowcontrol bit to detect when the pause completes. the value of the internal counter in the ?w-control module can be read out via the flowcontrolstatus register. if the mirrorcounter is non-zero, the flowcontrolstatus register will return the value of the internal mirror counter; if the mirrorcounter is zero, the flowcontrolstatus register will return the value of the internal pause counter value. the device driver may dynamically modify the mirrorcounter register value and switch between zero mirrorcounter and non-zero-valued mirrorcounter modes. transmit ?w control is enabled via the tx_flow_control bit in the mac1 con?uration register. if the tx_flow_control bit is zero, then the mac will not transmit pause control frames, and software must not initiate pause frame transmissions, and the txflowcontrol bit in the command register should be zero.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-61 transmit flow control example figure 12 illustrates the transmit ?w control. in this example, the lan100 receives a packet while transmitting another packet (operating in full duplex.) the device driver detects some buffer might overrun, and enables the transmit ?w control by programming the pausetimer and mirrorcounter ?lds of the flowcontrolcounter register after which it enables the transmit ?w control by setting the txflowcontrol bit in the command register. in response to enabling ?w control, the lan100 will send out a pause control frame on the lan after the packet currently being transmitted has ?ished. when the pause frame transmission completes, the internal mirror counter will start counting bit slots. as soon as the counter reaches the value in the mirrorcounter ?ld, another pause frame is transmitted. while counting, the transmit datapath will continue normal transmissions. as soon as software disables transmit ?w control, a zero-pause control frame is transmitted to resume the receive process. 5.11 half-duplex mode back pressure in half-duplex mode, the lan100 can generate back pressure to stall receive packets by sending a continuous preamble that basically jams any other transmissions on the ethernet medium. when the ethernet module operates in half-duplex mode, asserting the txflowcontrol bit in the command register will cause continuous preamble to be applied on the ethernet wire, effectively blocking traf? from any other ethernet station on the same segment. figure 12: transmit ?w control 0 50 100 150 200 250 300 350 400 450 500 t x clk cycles pausetimer, mirrorcounter, txflowctrl clear txflowctrl normal transmission pause control frame transmission normal receive normal receive transmission pause control frame transmission pause control frame normal receive mmio mii transmit mirrorcounter (1/515 bit slots) mii receive normal transmission pause
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-62 in half-duplex mode, when the txflowcontrol bit goes high, continuous preamble is sent until txflowcontrol is deasserted. if the medium is idle, the lan100 begins transmitting its preamble, which raises carrier sense, causing all other stations to defer. in the event that transmitting the preamble causes a collision, the back pressure ?ides through the collision. the colliding station backs off, and then defers to the back pressure. during back pressure, if the user wishes to send a frame, the back pressure is interrupted, the frame is sent, and then the back pressure is resumed. if txflowcontrol is asserted for longer than 3.3 ms in 10 mbps mode or 0.33 ms in 100 mbps mode, back pressure will cease sending preamble for several byte times to avoid the jabber limit. 5.12 receive ?tering 5.12.1 overview the ethernet module can ?ter out receive packets, analyzing the ethernet destination address in the packet. this capability greatly reduces the load on the host system, because the many ethernet packets that are typically addressed to other stations would otherwise have to be inspected and rejected by the device driver software, while using up bandwidth, memory space and host cpu time. address ?tering can be implemented using the perfect address ?ter or the (imperfect) hash ?ter. the latter produces a 6-bit hash code which can be used as an index into a 64-entry programmable hash table. in addition to the destination address, other portions of a packet can be included in the ?ter decision by using a pattern match ?ter. the result of the pattern-matching ?ter can be combined with the address ?tering to create the ?al ?tering result. the receive ?ter has two modes: and mode: the andor bit of the rxfilterctrl register is set to 1. the result of the perfect address ?ter and the hash ?ter is ored into a partial result which is anded with the result of the pattern-matching ?ter. if the pattern-matching ?ter is not enabled, the ?ter will not pass any packets. or mode: the andor bit of the rxfilterctrl register is set to 0. the result of the perfect address ?ter and the hash ?ter is ored into a partial result which is ored with the result of the pattern-matching ?ter.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-63 figure 13 depicts a functional view of the receive ?ter. on the top of the diagram, the ethernet receive packet enters the ?ters. each ?ter is controlled by signals from the software view. each ?ter produces a ?eady?output and a ?atch?output. if ready is 0, then the match value is ?on? care? a ?ter will assert its ready output when it is ?ished. if the ?ter ?ds a packet that matches, it will assert its match output along with its ready output. the results of the ?ters are combined by logic functions into a single rxabort output. if the rxabort output is asserted, the packet need not be received. the blocks in the left-hand side of the diagram are used for wol and are discussed in section 5.13 . in order to reduce memory traf?, the receive datapath of the lan100 has a fifo buffer that stores 68 bytes of receive data, so the lan100 will only start writing the received packet to memory after a 68-byte delay. if the rxabort signal is asserted during the initial 68 bytes of the packet, the packet can be discarded. the packet will be removed from the buffer and not stored to memory at all, thereby also not using any receive descriptors. if the rxabort signal is asserted after the initial 68 bytes in a packet, part of the packet is already written to memory, and the lan100 will stop writing further data in the packet to memory; the failfilter bit in the status word of the packet will be set to indicate the software device driver can discard the packet immediately. figure 13: receive ?ter block diagram packet acceptunicasten acceptmulticasten acceptbroadcasten acceptmulticasthashen acceptunicasthashen hashfilter imperfect stationaddress acceptperfecten perfect patternmatchen patternmatchjoin patternmatchmask0/1/2/3 patternmatchcrc0/1/2/3 patternmatchskip0/1/2/3 pattern hfready hfmatch and or and and/ or paready pamatch fmatch crc ok? rxfilterwol rxfilterenwol and fready and fmatch andor fready fready and ~fmatch rxabort hash filter hash filter match filter
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-64 5.12.2 unicast, broadcast and multicast generic ?tering based on the type of packet (where the types are unicast, multicast or broadcast) can be programmed using the acceptunicasten, acceptmulticasten and acceptbroadcasten bits from the rxfilterctrl register. setting the acceptunicast, acceptmulticast and acceptbroadcast bits causes all packets of types unicast, multicast and broadcast, respectively, to be accepted, ignoring the ethernet destination address in the packet. to program ?romiscuous mode? that is, to accept all packets, set all 3 bits to 1. 5.12.3 perfect address match when a packet with a unicast destination address is received, a perfect ?ter compares the destination address with the 6-byte station address (programmed in the station address registers sa0, sa1, and sa2). if the acceptperfecten bit in the rxfilterctrl register is set to 1, and the address matches, the packet is accepted. 5.12.4 imperfect hash filtering an imperfect ?ter is available, based on a hash mechanism. this ?ter applies a hash function to the destination address and uses the hash to access a table that indicates if the packet should be accepted. the advantage of this type of ?ter is that a small table can cover any possible address. the disadvantage is that the ?tering is imperfect, meaning that sometimes packets are accepted that should have been discarded. hash function the standard ethernet cyclic redundancy check (crc) function is calculated from the 6-byte destination address in the ethernet packet (this crc is calculated anyway as part of calculating the crc of the whole packet), then bits [28:23] out of the 32 bits crc result are taken to form the hash. the 6-bit hash is used to access the hash table: it is used as an index in the 64-bit hashfilter register that has been programmed with values that are to be accepted. if the selected value is set to 1, the packet is accepted. the device driver can initialize the hash ?ter table by writing to the registers hashfilterl and hash?terh. hashfilterl contains bits 0 through 31 of the table and hashfilterh contains bit 32 through 63 of the table. so, hash value 0 corresponds to bit 0 of the hash?terl register and hash value 63 corresponds to bit 31 of the hashfilterh register. multicast and unicast the imperfect hash ?ter can be applied to multicast addresses by setting the acceptmulticasthashen bit in the rxfilter register to 1. the same imperfect hash ?ter that is available for multicast addresses can also be used for unicast addresses. this is useful in order to respond to a multitude of unicast addresses without enabling all unicast addresses. the hash ?ter can be applied to unicast addresses by setting the acceptunicasthashen bit in the rxfilter register to 1.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-65 5.12.5 pattern match filtering and logic functions the lan100 has four pattern-matching ?ters. each ?ter is capable of covering 64-byte window in any location speci?d by patternmatchskip0/1/2/3[10:0] registers. the pattern match ?ters analyze received packets for certain patterns. if the ?ter ?ds a match, the ?ter asserts its match signal. depending on the join function and the ?ndor?relation with other ?ters, the packet is then accepted or rejected. the pattern-matching ?ters are imperfect ?ters. they calculate a 32-bit crc on a 64-byte window. the window can have an offset as speci?d by the associated patternmatchskip register. the skip register is 11 bits wide, allowing up to 2047 bytes at the start of the packet to be skipped. the patternmatchmask registers specify a mask for the pattern matching windows so that some bytes can be masked out in the crc calculation. a byte is only input in the crc calculation if the corresponding byte enable bit in the patternmatchmask register is set. a pattern match ?ter produces a match if the calculated crc matches the crc in the associated patternmatchcrc register. each of the four pattern match ?ters is enabled by setting the corresponding patternmatchen[3:0] bit in the rxfilter register to 1. the same 32-bit crc and polynomial are used as with the standard ethernet crc. the patternmatchmask register is 64 bits long, allowing up to 64 consecutive bytes of the received packet to be included in the crc calculation. when bit b in the patternmatch register is 1 and the value of the skip register is s , then receive packet byte number ( s + b ) is included in the crc calculation. counting starts at the destination address ?ld of the ethernet mac frame. the patternmatchmask register is split into low-order and high-order parts, and registers patternmatchmaskl and patternmatchmaskh are each 32 bits wide. there are four separate pattern-matching ?ters supported, and there are 4 sets of related registers (patternmatchmaskl0/1/2/3, patternmatchmaskh0/1/2/3, patternmatchcrc0/1/2/3, patternmatchskip0/1/2/3), one set for each ?ter. the patternmatchjoin register bits allow several of the pattern matches to be combined together to implement a more complex combined check. this can be used to create a pattern match of more than 64 bits, and the multiple pattern matches do not need to check adjacent portions of the receive packet. section 3.3 de?es the patternmatchjoin register. for example, if the patternmatchjoin register is set to 0xafaff0, then the results of the pattern-match ?ter 0 and pattern-match ?ter 1 will be anded together, while the results of ?ter 2 and 3 will be ignored. if the patternmatchjoin register is set to 0x7a1bb1, then the join logic will perform the complex function: ( a & ! b ) | c | ! d where a , b , c , d are the results from the 0/1/2/3 ?ters. a pattern match is enabled by setting the corresponding patternmatchen bit in the rxfilterwolcontrol register to 1. this can be done separately for each of the four ?ters. if the system is in power-down mode, if a pattern match detects a wake-up event, the corresponding patternmatch bit in the rxfilterstatus register is set. if the
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-66 rxfilterwolen is also enabled, a wake up event will cause an interrupt to the system, and the rxfilterwol in the rxfilterstatus register will be also be set. all the status bits in rxfilterstatus must be cleared by software after the system is powered up. however when the system is powered up and is receiving packets normally, the corresponding patternmatch bit in the rxfilterstatus register for each one of the four pattern-match ?ters is put in status display mode for the incoming packet. they are read-only, and there is no need to clear them. when multiple pattern matches are joined, their patternmatch bits are all set together based on the outcome of the joined pattern match. 5.12.6 enabling and disabling filtering the pattern-matching ?ters described in the previous sections can be bypassed by setting the passrxfilter bit in the command register. when the passrxfilter bit is set, all receive packets will be passed to memory. in this case the device driver software must implement all ?tering functionality in software. setting the passrxfilter bit does not affect the runt frame ?tering as de?ed in the next section. 5.12.7 runt frames a packet with less than 64 bytes (or 68 bytes for vlan frames) is shorter than the minimum ethernet frame size, and therefore is considered erroneous. for example, they might be collision fragments. the receive datapath automatically ?ters and discards runt frames without writing them to memory and without using a receive descriptor. when a runt frame has a correct crc, there is a possibility that it is intended to be useful. the device driver can receive runt frames with correct crc by setting the passruntframe bit of the command register to 1. 5.13 wake-up on lan 5.13.1 overview the ethernet module supports power management with remote wake-up over a local area network. the host system of the ethernet module can be powered down, even including part of the lan100 ethernet module itself, while the ethernet module continues to listen to packets on the lan. packets that are appropriately formed can be received and recognized by the ethernet module, and can be used to trigger the host system to wake up from its power-down state. system wake-up takes effect through an interrupt. when a wake-up event is detected, the wakeupint bit in the intstatus register is set. the interrupt status will trigger an interrupt if the corresponding wakeupinten bit in the intenable register is set. while in a power-down state, the packet that generates a wake-up-on-lan event is lost. there are two ways in which ethernet packets can trigger wake-up events: generic wake-up on lan and magic packet. the generic wake-up-on-lan functionality is based on the ?tering as de?ed in section 5.12 ; magic packet ?tering uses an
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-67 additional ?ter for magic packet detection. in both cases, a wol event is only triggered if the triggering packet has a valid crc. figure 13 illustrates the wake-up functionality. the following subsections describe the two wol mechanisms. the rxfilterwolstatus register can be read by the software to inspect the reason for a wake-up event. before going into a power-down condition, the power management software should clear the register by writing the rxfilterwolclear register. 5.13.2 filtering for wol the receive ?ter functionality as described in section 5.12 can be used to generate wol events. if the rxfilterenwol bit of the rxfilterctrl register is set, the receive ?ter will set the wakeupint bit of the intstatus register if a packet is received that passes the ?ter. the interrupt will only be generated if the crc of the packet is correct. in case a wake-up is generated by the receive ?ter, the rxfilterwol bit in the rxfilterwolstatus register will be set along with the origin of the ?ter match, which will be set in the acceptperfectwol, acceptmulticasthashwol, acceptunicasthashwol, acceptmulticastwol, acceptbroadcastwol, acceptunicastwol bits of the same register. software can reset these bits by writing a 1 to the corresponding bits of the rxfilterwolclear register. 5.13.3 magic packet wol the lan100 supports wake-up using amd's magic packet technology (see ?agic packet technology? advanced micro devices). a magic packet is a specially formed packet solely intended for wake-up purposes. this packet can be received, analyzed and recognized by the ethernet module and used to trigger a wake-up event. a packet is a magic packet if it contains the station address repeated 16 times in its data portion with no breaks or interruptions, preceded by six synchronization bytes with the value 0xff. other data may surround the magic packet pattern in the data portion of the packet. the whole packet must be a well-formed ethernet frame. the magic packet detection unit analyzes the ethernet packets, extracts the packet address and checks the payload for the magic packet pattern. the address from the packet is used for matching the pattern (not the address in the sa0/1/2 registers). a magic packet only sets the wake-up interrupt status bit if the packet passes the receive ?ter, as illustrated in ?ure figure 13 : the result of the receive ?ter is anded with the magic packet ?ter result to produce the ?al result. magic packet ?tering is enabled by setting the magicpacketenwol bit of the rxfilterctrl register. note that when doing magic packet wol, the rxfilterenwol bit in the rxfilterctrl register should be 0. setting the rxfilterenwol bit to 1 would accept all packets for a matching address, not just the magic packets, that is, wol using magic packets is more strict.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-68 when a magic packet is detected, apart from the wakeupint bit in the intstatus register, the magicpacketwol bit is set in the rxfilterwolstatus register. software can reset the bit by writing a 1 to the corresponding bit of the rxfilterwolclear register. magic packet wol example an example of a magic packet with station address 11h 22h 33h 44h 55h 66h is as follows. misc indicates miscellaneous additional data bytes in the packet. destination source misc ff ff ff ff ff ff 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 11 22 33 44 55 66 misc crc 5.14 enabling and disabling receive and transmit 5.14.1 enabling and disabling reception after reset, the receive function of the lan100 is disabled. the receive function can be enabled by the device driver by setting the rxenable bit in the command register and the receive_enable bit in the mac1 con?uration register of the lan100. the status of the receive datapath can be monitored by the device driver by reading the rxstatus bit of the status register. figure 14 illustrates the ?ite state machine (fsm) for generating the rxstatus bit. figure 14: receive active/inactive state machine rxenable !rxenable && not busy receiving active rxstatus=1 inactive rxstatus=0 reset
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-69 after a reset, the fsm is in the inactive state. as soon as the rxenable bit is set in the command register, the fsm transitions to the active state. as soon as the rxenable bit is cleared, the fsm returns to the inactive state. if the receive datapath is busy receiving a packet when it is put in the disabled state, packet reception will continue and the packet will be received completely and stored to memory along with its status before it returns to the inactive state. as shown in figure 14 , after a soft reset (see section 5.19.2 ), the receive datapath is inactive until the datapath is re-enabled. 5.14.2 enabling and disabling transmission after reset, the transmit function of the lan100 is disabled. the transmit datapaths (tx and txrt) must be enabled separately. the device driver enables the tx datapath by setting the txenable bit in the command register to 1. the device driver enables the txrt datapath by setting the txrt bit in the command register to 1. the status of the transmit datapaths can be monitored by the device driver by reading the txstatus and txrtstatus bits of the status register. the fsm for both tx and txrt are the same, as shown in figure 15 . . after reset, the fsms are in the inactive state. as soon as the tx(rt)enable bit is set in the command register and the produce and consume indices are not equal, the fsm transitions to the active state. as soon as the tx(rt)enable bit is cleared and the transmit datapath has completed all pending transmissions including committing the transmission status to memory, the fsm returns to the inactive state. the fsm will also return to the inactive state if the produce and consume indices are equal again, that is, when all packets have been transmitted. as shown in figure 15 , the transmit datapath is inactive after a soft reset (see section 5.19.2 ) until the datapath is re-enabled. 5.15 transmission padding and crc in the event that a packet is received with a length of less than 60 bytes (or 64 bytes for vlan frames) the lan100 can pad the packet to 64 or 68 bytes, including a 4-byte crc frame check sequence (fcs). padding is affected by the value of the figure 15: transmit active/inactive state machine active rxstatus=1 inactive rxstatus=0 reset txenable && txproduceindex != txconsumeindex (!txenable && not busy transmitting) || txproduceindex == txconsumeindex
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-70 auto_detect_pad_enable (adpen), vlan_pad_enable (vlpen) and pad_crc_enable (paden) bits of the mac2 con?uration register as well as the override and pad bits from the transmit descriptor control word. crc generation is affected by the crc_enable (crce) and delayed_crc (dcrc) bits of the mac2 con?uration register and the override and crc bits from the transmit descriptor control word. the effective pad enable (epaden) is equal to the pad_crc_enable bit from the mac2 register if the override bit in the descriptor is 0. if the override bit is 1, then epaden will be taken from the descriptor pad bit. likewise, the effective crc enable (ecrce) equals crce if the override bit is 0, otherwise it equal the crc bit from the descriptor. if padding is required and enabled, a crc will always be appended to the padded frames. a crc will only be appended to the non-padded frames if ecrce is set. if epaden is 0, the packet will not be padded, and no crc will be added unless ecrce is set. if epaden is 1, then small packets will be padded, and a crc will always be added to the padded frames. in this case, if adpen and vlpen are both 0, then the packets will be padded to 60 bytes, and a crc will be added, creating 64-byte packets. if vlpen is 1, the packets will be padded to 64 bytes and a crc will be added, creating 68 bytes packets. if adpen is 1 while vlpen is 0, vlan packets will be padded to 64 bytes, non-vlan packets will be padded to 60 bytes, and a crc will be added to padded packets creating 64- or 68-byte padded packets. in case crc generation is enabled, crc generation can be delayed by four bytes to skip proprietary header information. 5.16 huge frames and frame length checking the huge_frame_enable bit in the mac2 con?uration register can be set to 1 to enable transmission and reception of packets of any length. huge frame transmission can be enabled on a per-packet basis by setting the override and huge bits in the transmit descriptor control word. when enabling huge frames, the lan100 will not check frame lengths or report frame length errors (rangeerror and lengtherror). if huge frames are enabled, the received byte count in the rsv register may be invalid because the frame may exceed the maximum size. however, the entrylevel ?lds from the receive status arrays will be valid. the lan100 will check frame lengths by comparing the length/type ?ld of the packet to the actual number of bytes in the packet, and report a lengtherror by setting the corresponding bit in the receive statusinfo word. the maxf register in the lan100 allows the device driver to specify the maximum number of bytes in a frame. the lan100 will compare the actual receive frame to the maxf value and report a rangeerror in the receive statusinfo word if the packet is larger.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-71 5.17 statistics counters in ethernet applications generally, many counters that keep ethernet traf? statistics must be maintained. there are a number of standards specifying such counters, such as ieee std 802.3 / clause 30. other standards are rfc 2665 and rfc 2233. the approach taken here is as follows: by default, all counters are implemented in software. with the help of the statusinfo ?ld in the packet status word, many of the important statistics events listed in the standards can be counted by software. currently, no counters are added in hardware. 5.18 status vectors a transmit status vector and a receive status vector are available in registers tsv0, tsv1, and rsv. these registers can be polled with software. normally, they are of limited use, because the communication between driver software and ethernet module takes place primarily through the packet descriptors. statistical events are counted by software in the device driver. however, these transmit and receive status vectors are made visible for debug purposes. the values in these registers are simple copies of the transmit and receive status vectors as produced by the mii interface. they are valid as long as the status vectors are valid, and should typically only be read when the transmit and receive processes are halted. the tsv0, tsv1 and rsv registers are de?ed in section 3.2 . 5.19 reset the lan100 has a hard reset input and several soft resets which can be activated by setting the appropriate bits in its registers. all registers in the lan100 have a reset value of 0 unless speci?d differently in section 3.2 . 5.19.1 hard reset the lan100 module experiences a hard reset when the pnx15xx series is reset. after a hard reset, all register values in the software view will be set to their default value as speci?d in section 3.2 . 5.19.2 soft reset parts of the lan100 can be reset by software by setting bits in the command register and the mac1 con?uration register. the mac1 register has six different reset bits: soft_reset: setting this bit will put all components in the mii interface in the reset state except for the mii interface registers (in address locations 72 0000 to 72 00fc). the soft reset bit defaults to 1, and must be cleared after a hardware reset to enable the mii interface. simulation_reset: setting this bit resets the random number generator in the transmit function. the value after a hard reset is 0.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-72 reset_pemcs_rx: setting this bit will reset the mac control sublayer (the pause frame logic) and the receive function of the mii interface. the value after a hard reset is 0. reset_perfun: setting this bit will reset the receive function in the mii interface. the value after a hard reset is 0. reset_pemcs_tx: setting this bit will reset the mac control sublayer (pause frame logic) and the transmit function of the mii interface. the value after a hard reset is 0. reset_petfun: setting this bit will reset the transmit function of the mii interface. the value after a hard reset is 0. all the above reset bits must be cleared by software. the reset_permii bit in the supp register allows soft resetting of the rmii logic. the reset must be cleared by software. the command register (see t ab le 2 ) has three different reset bits: txreset: writing a 1 to the txreset bit will reset the transmit datapath, excluding the mii interface portions, including all (read-only) registers in the transmit datapath, and also the txproduceindex register in the host registers module. soft resetting the transmit datapath will abort all memory operations of the transmit datapath. the reset bit will be cleared automatically by the lan100. soft resetting the tx datapath will clear the txstatus and txrtstatus bits in the status register. rxreset: writing a 1 to the rxreset bit will reset the receive datapath, excluding the mii interface portions, including all (read-only) registers in the receive datapath, and also the rxconsumeindex register in the host registers module. soft resetting the receive datapath will abort all memory operations of the receive datapath. the reset bit will be cleared automatically by the lan100. soft resetting the rx datapath will clear the rxstatus bit in the status register. regreset: writing a 1 to the regreset bit resets all of the datapaths and lan100 registers, but not the registers in the mii interface. soft resetting the registers aborts all memory operations of the transmit and receive datapaths. the reset bit will be cleared automatically by the lan100. to do a full soft reset of the lan100 device driver, software must: set the soft_reset bit in the mac1 register to 1 set the regreset bit in the command register (this bit clears automatically) reinitialize the mii interface registers (0x000-0x0fc) clear the soft_reset bit in the mac1 register to 0. to reset just the transmit datapath, the device driver software must: set the reset_pemcs_tx bit in the mac1 register to 1
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-73 disable the tx dma managers by setting the tx(rt)enable bits in the command register to 0 set the txreset bit in the command register (this bit clears automatically) reset the reset_pemcs_tx bit in the mac1 register to 0. to reset just the receive datapath the device driver software must: disable the receive function by resetting the receive_enable bit in the mac1 con?uration register and resetting of the rxenable bit of the command register. set the reset_pemcs_rx bit in the mac1 register to 1 set the rxreset bit in the command register (this bit clears automatically) reset the reset_pemcs_rx bit in the mac1 register to 0. a soft reset of the transmit datapaths will abort any transmit-descriptor read, status-write, and data-read operations. a soft reset of the receive datapath will abort any receive-descriptor read, status-write and data-write operations. 6. system integration 6.1 mii interface i/o t ab le 12 summarizes the pin interface of the lan100. table 12: lan100 pin interface to external phy pin directio n description lan_clk out clock to feed the external phy, usually 50 mhz lan_tx_clk/lan_ref_clk in mii transmit clock or rmii reference clock lan_tx_en out mii or rmii transmit enable lan_txd3 lan_txd2 lan_txd1 lan_txd0 out mii transmit data mii transmit data mii or rmii transmit data mii or rmii transmit data lan_tx_er out mii transmit error lan_crs/lan_crs_dv in mii carrier sense or rmii carrier sense and receive data valid. this pin is 5 v input tolerant. lan_col in collision detect. this pin is 5 v input tolerant. lan_rx_clk in mii receive clock lan_rxd3 lan_rxd2 lan_rxd1 lan_rxd0 in mii receive data mii receive data mii or rmii receive data mii or rmii receive data lan_rx_dv in mii receive data valid
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-74 6.2 power management the lan100 supports power management by means of external clock switching. basically, all clocks in the lan100 module can be switched off. if wol is needed, the receive clock should not be switched off. the lan100 supports two power management modes: sleep mode : the pnx15xx series is active while most clocks are switched off. the cpu is active and can still communicate with the lan100 via mmio registers. coma mode : most of the clocks in the pnx15xx series are switched off, including the lan100, cpu, and mmio clock. 6.2.1 sleep mode the lan100 can be put in sleep mode by setting the powerdown bit in the powerdown register if the receive and transmit dma managers are disabled and inactive. clocks should only be disabled after software has set the powerdown bit. software should prevent access to components of the lan100 that have been switched off. if an external phy is connected, a wol can still trigger an interrupt. to enter sleep mode, software should: disable both transmit dma managers and the receive dma manager by writing the command register wait for the transmit and receive datapaths to be inactive by waiting for a finished interrupt or by polling the status register. set the powerdown bit by writing to the powerdown register. if no phy is connected software can directly set the powerdown bit and disable the clocks. to exit sleep mode sofware should: reset the powerdown bit reenable the receive and transmit datapaths. 6.2.2 coma mode in coma mode, most of the clocks in the pnx15xx series can be switched off including the cpu and mmio clocks. if an external phy is connected, the receive ?ter and wol detection will still be active and capable of generating a wol interrupt to the systems power-management controller. lan_rx_er in mii or rmii receive error lan_mdio in/out mii management data i/o lan_mdc out mii management data clock table 12: lan100 pin interface to external phy ?ontinued pin directio n description
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-75 to enter coma mode, software should ?st enter sleep mode. the systems power-management controller can then disable the mmio clock. to exit coma mode, software should re-enable the mmio clock before following the wake-up step from section 6.2.1 . 6.3 disabling the lan100 in implementations that do require ethernet functionality, the external phy can be omitted, and the i/o pins from the phy, including the clock inputs, can be tied to 0 or 1. in this case, software should switch the lan100 to sleep mode by setting the powerdown bit in the powerdown register. 6.4 little/big endian the lan100 memory interfaces take care of the conversion to the endian mode of the pnx15xx series system buses. when packing multiple ethernet bytes into a word in order to optimize bus traf?, the lan100 orders the bytes as required by the system bus. internally, all components of the lan100 use bytes as the native width for transmission and reception of data. therefore, the lan100 itself is endian insensitive. 6.5 interrupts the lan100 has a single interrupt request output directed to the cpu. after taking the interrupt, the cpus interrupt service routine must read the intstatus register to locate the origin of the interrupt. software interrupt conditions can be set by writing to the intset register; interrupt conditions can be cleared by writing to the intclear register. the transmit and receive datapaths can only set interrupt status, they cannot clear status. the softint interrupt cannot be set by hardware and can be used by software for test purposes. for more information on the source of an interrupt refer to section 5.4.8 and section 5.5.7 . 6.6 errors and aborts several conditions cause the lan100 to generate errors: an illegal mmio access can cause an mmio error response as de?ed in section 5.1 . these errors are handled by the mmio adapter, which may be propagated back to the cpu across the system bus. if the powerdown bit is set, any access to mmio registers will result in an error response except for access to the powerdown register. packet reception can cause errors, including alignmenterror, rangeerror, lengtherror, symbolerror, crcerror, nodescriptor, and overrun. these errors are reported in the receive status word and in the interrupt status register. for more information refer to section 4.1 and section 5.5 .
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-76 packet transmission can cause errors including latecollision, excessivecollision, excessivedefer, nodescriptor, and underrun. these errors are reported back in the transmission status word and in the interrupt status register. for more information refer to section 4.2 and section 5.4 . 6.7 cache coherency because the device driver can produce descriptors with write-only operations and consume the status ?lds with read-only operations, transfers can be made ?ache safe,?and descriptors can be packed together in cache blocks and cached. status words can also be packed together. the device driver must take care of cache coherency if cache coherency is not enforced by a snooping cache in the host processor. if the device driver doesn? own all of the status words in a cache block that contains multiple status words, then the ethernet hardware may be writing to a status ?ld in memory while that status is also included in a cache block loaded in the host processors cache, causing the values for that status in the host cache to be stale. this can be solved by invalidating these cache blocks and causing them to be read again from the host memory whenever the device driver receives ownership of these status words, that is, when the tx(rt)consumeindex or rxproduceindex are updated. before updating the tx(rt)produceindex or rxconsumeindex, the device driver must make sure the associated descriptors are written back from the cache to the memory so that the new descriptor values become visible to the ethernet hardware. when ?shing these cache blocks, care must be taken not to modify the ?lds of descriptors that are already owned by the ethernet hardware. alternatively, the device driver can use non-cached memory traf? for the descriptors and statuses. in that case, there is no need to worry about cache coherency, however, a higher amount of memory traf? may be required for the descriptors and status words.
philips semiconductors pnx15xx series volume 1 of 1 chapter 23: lan100 ?ethernet media access controller 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 23-77 references [1] ieee std 802.3, 2000 edition, (incorporating ieee std 802.3, 1998 edition, ieee std 802.3ac-1998, ieee std 802.3ab-1999, and 802.3ad-2000)ieee standard 802.3 [2] mii interface packet engines 10/100 mbps ethernet media access controller with mii management interface, release 3.5, 2001 [3] pe-rmii reduced media independent interface for the alcatel 10/100 mb/s ethernet media acces controller, release 3.2, 2002.
1. introduction the tm3260 debug (tm_dbg) interface consists of the test access port (tap), the tap controller, a jtag instruction register and internal debug registers. the tap controller from which the tm_dbg module receives its commands resides in the test control block, which also facilitates boundary scanning and other dft features. 1.1 features the tm_dbg has registers that can be programmed for control and communication with an on-chip trimedia tm3260 cpu. 2. functional description 2.1 general operations 2.1.1 test access port (tap) the test access port (tap) includes four dedicated input pins and one output pin: tck (test clock) tms (test mode select) tdi (test data in) tdo (test data out) tck provides the clock for test logic required by the jtag standard. tck is asynchronous to any system clock. stored state devices in the jtag controller will retain their state inde?itely when tck is stopped at 0 or 1. the signal received at tms is decoded by the tap controller to control test functions. the test logic is required to sample tms at the rising edge of tck. serial test instructions and test data are received at tdi. the tdi signal is required to be sampled at the rising edge of tck. when test data is shifted from tdi to tdo, the data must appear without inversion at tdo after a number of rising and falling edges of tck determined by the length of the instruction or test data register selected. chapter 24: tm3260 debug pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-2 tdo is the serial output for test instructions and data from the tap controller. changes in the state of tdo must occur at the falling edge of tck. this is because devices connected to tdo are required to sample tdo at the rising edge of tck. the tdo driver must be in an inactive state (i.e., tdo line highz) except when the scanning of data is in progress. 2.1.2 tap controller the tap controller is a ?ite state machine that synchronously responds to changes in tck and tms signals. the tap instructions and data are serially scanned into the tap controllers instruction and data registers via the common input line tdi. the tms signal tells the tap controller to select either the tap instruction register or a tap data registers as the destination for serial input from the common line tdi. an instruction scanned into the instruction register selects a data register to be connected between tdi and tdo to become the destination for serial data input. the tap controllers state changes are determined by the tms signal. the states are used for scanning in/out tap instruction and data, updating instruction, and data registers, and for executing instructions.
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-3 the controllers state diagram ( figure 1 ) shows separate states for ?apture, ?hift and ?pdate of data and instructions in order to leave the contents of a data register or an instruction register undisturbed until serial scan in is ?ished and the update state is entered. by separating the shift and update states, the contents of a register (the parallel stage) is not affected during scan in/out. the tap controller must be in test logic reset state after power up. it remains in that state as long as tms is held at 1. the controller transitions to run-test/idle state from test logic reset state when tms = 0. the run-test/idle state is an idle state of the controller in between scanning in/out an instruction/data register. the ?un-test part of the name refers to start of built-in tests. the ?dle part of the name refers to all other cases. note that there are two similar substructures in the state diagram, one for scanning in an instruction and another for scanning in data. to scan in/out a data register, one has to scan in an instruction ?st. an instruction or data register must have at least two stages, the shift register stage and the parallel input/output stage. when an n-bit data register is to be ?ead,?the register is selected by an instruction. the registers contents are ?aptured??st figure 1: state diagram of tap controller 0 0 1 0 1 1 0 0 1 1 select dr scan capture dr shift dr exit1 dr pause dr exit2 dr update dr 0 0 1 0 1 1 0 0 1 1 select ir scan capture ir shift ir exit1 ir pause ir exit2 ir update ir 1 1 0 1 0 1 test logic reset run-test/ idle 1 1 00 0 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-4 (loaded in parallel into the shift register stage), n bits are shifted in and simultaneously, n bits are shifted out. finally the register is ?pdated?with the new n bits shifted in. note that when a register is scanned, its old value is shifted out of tdo and the new value shifted in via tdi is written to the register at the update state. hence, scan in/ out involve the same steps. this also means that reading a register via jtag destroys its contents unless otherwise stated. some registers are speci?d as read-only via jtag so that when the controller transitions to the update state for the read-only register, the update has no effect. some times, read/write registers are needed (e.g., control registers used for handshake) which must be read non-destructively. in such cases, the value shifted in determines whether the old value is ?emembered?or something else happens. 2.1.3 pnx15xx series jtag instruction set pnx15xx series uses a 5-bit jtag instruction register. the unspeci?d opcodes are private and their effects are unde?ed. t ab le 1 lists the jtag instructions related to tm_dbg module. the standard jtag instructions such as extest, sample/preload, bypass and idcode are implemented and listed in t ab le 2 . 3. operation 3.1 register programming guidelines because the jtag data registers live in mmio space and are accessible by both the tm3260 cpu and the jtag controller at the same time, race conditions must not exist either in hardware or in software. the communication protocol uses a handshake mechanism to avoid software race conditions. table 1: jtag tm3260 instruction encoding encodin g instruction name action 10001 tm_dbg_sel_data_in select tm_dbg_data_in register 10010 tm_dbg_sel_data_out select tm_dbg_data_out register 10011 tm_dbg_sel_ifull_in select tm_dbg_ifull_in register 10100 tm_dbg_sel_ofull_out select tm_dbg_ofull_out register 10101 tm_dbg_sel_tm_dbg_ctl1 select tm_dbg_ctrl register 1 10110 tm_dbg_sel_tm_dbg_ctl2 select tm_dbg_ctrl register 2 table 2: jtag instruction encoding encoding instruction name action 00000 extest select boundary scan register 00001 sample select boundary scan register 00010 icode select identi?ation register 11111 bypass select bypass register
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-5 3.1.1 handshaking and communication protocol the following describes the mechanism for transferring data via jtag. transfer from debug front-end to debug monitor the debugger front-end running on a host transfers data to a debug monitor via the tm_dbg_data_in register. it must poll the tm_dbg_ctrl2.ifull bit to check if the tm_dbg_data_in register can be written to. if the tm_dbg_ctrl2.ifull bit is clear, the front-end may scan data into the tm_dbg_data_ifull_in register. note that data and control bits may be shifted in with sel_ifull_in instruction and the bit shifted into tm_dbg_ctrl2.ifull register must be 1. this action triggers an interrupt. the debug monitor must copy the data from tm_dbg_data_in register into its private area when servicing the interrupt and then clear the tm_dbg_ctrl2.ifull bit. this allows the jtag interface module to write the next piece of data to the tm_dbg_data_in register. transfer from monitor to front-end the monitor running on tm3260 must check if tm_dbg_ctrl1.ofull is clear and if so, it can write data to tm_dbg_data_out. after that, the monitor must set the tm_dbg_ctrl1.ofull bit. the debugger front-end polls the tm_dbg_ctrl1.ofull bit. when set, it can scan out the tm_dbg_data_out register and clear the tm_dbg_ctrl1.ofull bit. since tm_dbg_data_out is read-only via jtag, the update action at the end of scan out has no effect on tm_dbg_data_ out. the tm_dbg_ctrl1.ofull bit however, must be cleared by shifting in the value 1. controller states in the power on reset state, tm_dbg_ctrl2.ifull, tm_dbg_ctrl1.ofull and tm_dbg_ctrl1.sleepless bits are cleared. example of data transfer via jtag scanning in a 5-bit instruction will take 12 tck cycles from the run-test/idle state: 4 cycles to reach shift-ir state 5 cycles for actual shifting in 1 cycle to exit1-ir state 1 cycle to update-ir state, 1 cycle back to run-test/idle state. likewise, scanning in a 32-bit data register will take 38 tck cycles, and transferring an 8-bit tm_dbg_ctrl data register will take 14 tck cycles from idle state. however, if a data transfer follows instruction transfer, then the transition to dr scan stage can be done without going through idle state, thereby saving 1 cycle.
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-6 transfer of data to tm3260 via jtag poll control register to check if input buffer is empty or not and scan in data when it is empty and set the ifull control bit to 1 triggering an interrupt. note that scanning in any instruction automatically scans out the 3 least signi?ant bits (including the ifull or ofull bit) of the selected tm_dbg_ctrl register. 3.2 debug settings figure 2 shows an overview of the jtag access path from a host machine to a target pnx15xx series system and a simpli?d block diagram of the pnx15xx series processor. the jtag interface module, shown separately in the diagram, may be a pc add-on card such as pc-1149.1/100f boundary scan controller board or a similar module connected to a pc serial or parallel port. the jtag interface module is necessary for pnx15xx series systems that are not plugged into a pc. for pc- hosted pnx15xx series systems, the host based tm3260 debugger front-end can communicate with the target resident debug monitor via the pci bus. enhancements to the standard jtag functionality include a handshake mechanism for transferring data to and from a pnx15xx series processors mmio registers, support for posting an interrupt, and resetting processor state. table 3: transfer of data in via jtag action number of tck cycles ir shift in sel_ifull_in instruction 12 while tm_dbg_ctrl2.ifull = 1, scan in sel_ifull_in instruction 11+ dr scan 33 bits of register tm_dbg_ifull_in 38 total 61+ cycles figure 2: system with jtag access host machine jtag interface jtag board connector serial or parallel connection jtag tap (tck, tms, tdi, tdo) main memory (sdram) tm3260 mcu i$ d$ jtag controller peripherals scan chain connecting possibly other chips on board internal system bus module (such as a pc) may be a pc plug-in boar d cpu
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-7 the actual interpretation of the contents of the mmio registers is determined by a software protocol used by the debug monitor running on the internal tm3260 cpu and the debug front-end running on a host machine. the communication between a host computer and a target system via jtag requires the following major components: 1. a host computer with a serial or parallel interface. the host computer transfers data to and from the jtag interface module, preferably in word-parallel fashion. also needed is jtag interface device driver software to access and modify the registers of the jtag interface module. 2. a jtag interface module (hardware) that asynchronously transfers data to and from the host computer. the interface module synchronously transfers data to and from the jtag tap on a pnx15xx series processor, supplies the test clock tck and other signals to the jtag controller on pnx15xx series. the interface module may be a pc plug-in board. this module may transfer data from and to the host computer in bit-serial or word-parallel fashion. it transfers data from and to the jtag registers on the pnx15xx series processor in bit-serial fashion in accordance with the ieee 1149.1 standard. the jtag interface module connects to a 4 or 5-pin jtag connector on the pnx15xx series board which provides a path to the jtag pins on the pnx15xx series processor. it is the responsibility of the interface module to scan data in and out of the pnx15xx series processor into its internal buffers and make them available to the host computer. 3. a jtag controller on the pnx15xx series processor which provides a bridge between the external jtag tap and the internal system. the controller transfers data from/to the tap to/from its scannable registers asynchronous to the internal system clock. a monitor running on the internal tm3260 cpu and the debugger front-end running on a host computer exchange data via jtag by reading/writing the mmio registers reserved for this purpose, including two control registers used for handshaking. 4. register descriptions the pnx15xx series has two jtag data registers and two jtag control registers (see figure 3 ) in mmio space and a number of jtag instructions to manipulate those registers. t ab le 4 lists the mmio addresses of the jtag data and control registers. the addresses are offsets from the mmio_base. remark: the sleepless bit is not used in pnx15xx series.
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-8 remark: all references to instruction and data registers refer to jtag instructions and data registers only (not tm3260 instruction or data registers). data registers there are two 32-bit data registers, tm_dbg_data_in and tm_dbg_data_out in the mmio space. both can be connected in between tdi and tdo like the standard bypass and boundary-scan registers of jtag. the tm_dbg_data_in register can be read or written to via the jtag port. the tm_dbg_data_out register is read-only via the jtag port, so that scanning out tm_dbg_data_out is non-destructive. the tm_dbg_data_in and tm_dbg_data_out are readable/writable from the tm3260 processor via the usual load/store operations. control registers there are two control registers, tm_dbg_ctrl1 and tm_dbg_ctrl2, in mmio space. the tm_dbg_ctrl registers are used for handshake between a debug monitor running on a tm3260 cpu and a debugger front-end running on a host. tm_dbg_ctrl1.ofull = 1 means that tm_dbg_data_out has valid data to be scanned out. on the power-on reset of the pnx15xx series, tm_dbg_ctrl1.ofull = 0. tm_dbg_ctrl1.ofull is both readable and writable via the jtag tap. writing 0 to tm_dbg_ctrl1.ofull via jtag is a ?emember operation i.e., tm_dbg_ctrl1.ofull retains its previous state. writing 1 to tm_dbg_ctrl1.ofull via jtag is a ?lear operation i.e., tm_dbg_ctrl1.ofull becomes 0. tm_dbg_ctrl2.ifull = 0 means that the tm_dbg_data_in register is empty. tm_dbg_ctrl2.ifull = 1 means that tm_dbg_data_in has valid data and the debug monitor has not yet copied it to its private area. upon power on reset of the tm3260 processor, tm_dbg_ctrl2.ifull = 0. tm_dbg_ctrl2.ifull is readable figure 3: additional jtag data and control registers to tdo tm_dbg_data_in tm_dbg_data_out tm_dbg_ctrl1 from tdi 0 0 ifull ofull unused bits 0 31 31 0 1 sleepless bit 2 unused bits tm_dbg_ctrl2 1
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-9 and writable via jtag. writing 0 to tm_dbg_ctrl2.ifull via jtag is a ?emember operation i.e., tm_dbg_ctrl2.ifull retains it previous state. writing 1 to tm_dbg_ctrl2.ifull posts a tm3260 interrupt on hardware line 49. the tm_dbg_ctrl1.sleepless bit has no longer a function. however it still can be read and written to by the pnx15xx series cpu via load/store operations and by the debugger front-end running on a host by scan in/out. jtag virtual registers there are two virtual registers, tm_dbg_ifull_in and tm_dbg_ofull_out: the ?st virtual register tm_dbg_ifull_in connects the registers tm_dbg_ctrl2.ifull and tm_dbg_data_in in series. likewise, the virtual register tm_dbg_ofull_out connects tm_dbg_ctrl1.ofull and tm_dbg_data_out in series. the reason for the virtual registers is to shorten the time for scanning the tm_dbg_data_in and tm_dbg_data_out registers. without virtual registers, one must scan in an instruction to select tm_dbg_data_in, scan in data, scan an instruction to select tm_dbg_ctrl register and ?ally scan in the control register. with virtual register, one can scan in an instruction to select tm_dbg_ifull_in and then scan in both control and data bits. similar savings can be achieved for scan out using virtual registers. 4.1 register summary table 4: register summary offset symbol description 0x06 1000 tm_dbg_n_data_in input register for data coming from the jtag 0x06 1004 tm_dbg_n_data_out output register for data going to the jtag 0x06 1008 tm_dbg_n_ctrl1 control register 1 for output data 0x06 100c tm_dbg_n_ctrl2 control register 2 for input data 0x06 1fe0 tm_dbg_n_int_st interrupt status register 0x06 1fe4 tm_dbg_n_int_en interrupt enable register 0x06 1fe8 tm_dbg_n_int_clr interrupt clear register 0x06 1fec tm_dbg_n_int_set interrupt set register 0x06 1ff0 reserved 0x06 1ff4 tm_dbg_n_power_down powerdown register 0x06 1ff8 reserved 0x06 1ffc module id module identi?ation register
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-10 table 5: tm_dbg 1 registers bit symbol acces s value description tm3260 debug registers offset 0x06 1000 tm_dbg_data_in 31:0 tm_dbg_data_in[31:0 ] r/w 0 tm_dbg debugger input data offset 0x06 1004 tm_dbg_data_out 31:0 tm_dbg_data_out[3 1:0] r/w 0 tm_dbg debugger output data offset 0x06 1008 tm_dbg_ctrl1 31:2 unused - 1 sleepless r/w 0 set bit to prevent tm_dbg debug module from going into powerdown. 0 ofull r/w 0 tm_dbg output data available handshake bit offset 0x06 100c tm_dbg_ctrl2 31:1 unused - 0 ifull r/w 0 tm_dbg input data available handshake bit offset 0x06 1fe0 tm_dbg_int_st 31:1 unused - 0 intr_status r 0 interrupt status register: a logic ??indicates jtag interrupt detected. offset 0x06 1fe4 tm_dbg_int_en 31:1 unused - 0 intr_en r/w 0 interrupt enable register: a logic ??written to this bit enables the corresponding interrupt in the interrupt status register. offset 0x06 1fe8 tm_dbg_int_clr 31:1 unused - 0 intr_clr w 0 interrupt clear register: a logic ??written to this bit clears the corresponding interrupt in the interrupt status register. this bit is self-clearing. offset 0x06 1fec tm_dbg_int_set 31:1 unused - 0 intr_set w 0 interrupt set register: a logic ??written to this bit sets the corresponding interrupt in the interrupt status register. offset 0x06 1ff4 tm_dbg_power_down 31 power_down r/w 0 tm_dbg powerdown indicator 1 = powerdown 0 = power up when this bit equals 1, no other registers are accessible. 30:0 unused - offset 0x06 1ffc module id 31:16 mod_id r 0x0127 tm_dbg module id number
philips semiconductors pnx15xx series volume 1 of 1 chapter 24: tm3260 debug 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 24-11 15:12 rev_major r 0 major revision 11:8 rev_minor r 0 minor revision 7:0 app_size r 0 aperture size is 0 = 4 kb. table 5: tm_dbg 1 registers ?ontinued bit symbol acces s value description
1. introduction the pnx15xx series chip contains an i 2 c module which interfaces with a variety of peripherals including consumer electronic appliances, video image processing equipment, and miniature cards. the iic module supports bi-directional data transfer between master and slave in slow and fast speeds as well as multiple master and slave modes. arbitration between simultaneously transmitting masters can be maintained without corruption of serial data on the bus. serial clock synchronization allows devices with different bit rates to communicate via one serial bus, and it can be used as a handshake mechanism to suspend and resume serial transfer. the iic hardware architecture and software protocol is simple and versatile. the on-chip iic module provides a serial interface that meets the i 2 c bus speci?ation and supports all transfer modes to and from the i 2 c bus. it supports the following functionality: both normal and fast modes up to 400 khz. 32-bit word access from the cpu; no buffering is supported. generation of interrupts on i 2 c state change four modes of operation: master transmitter and receiver, slave transmitter and receiver. sto bit and the actual addresses of the special function registers (sfrs). the i 2 c bus is a multi-master bus. this means that more than one device capable of controlling the bus can be connected to it. because more than one master could try to initiate a data transfer at the same time, a collision detection scheme is used to arbitrate between the multiple masters. if two or more masters attempt to transfer information onto the bus, the ?st to produce a ?ne when the other produces a zero will detect the collision and back off transferring information. the clock signals during arbitration are a synchronized combination of the clocks generated by the masters using the wired-and connection to the scl line. two wires, sda serial data) and scl (serial clock), carry information between the devices connected to the i 2 c bus. each device can operate as either a transmitter or receiver, depending on the function of the device. in addition to transmitters and receivers, devices can also be considered as masters or slaves when performing data transfers. a master is the device which initiates a data transfer on the bus and generates the clock signals to permit that transfer. any device addressed by a master is considered a slave. chapter 25: i 2 c interface pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-2 generation of clock signals on the i 2 c bus is always the responsibility of the master device. each master generates its own clock signals when transferring data on the bus. bus clock signals from a master can only be altered when they are stretched by a slow-slave device holding down the clock line or by another master when arbitration occurs. 1.1 features the main features of the i 2 c bus are as follows: bi-directional data transfer between masters and slaves multi-master bus (no central master) arbitration between simultaneously transmitting masters without corruption of serial data on the bus serial clock synchronization, which allows communication between devices with different bit rates using serial clock synchronization as a handshake mechanism to suspend and resume serial transfer may be used for test and diagnostic purposes. 2. functional description 2.1 general operations the iic module supports a master/slave i 2 c bus interface with an integrated shift register, shift timing generation and slave address recognition. it is compliant with the i 2 c bus speci?ation. both the i 2 c standard mode (100 khz scl) and fast mode (up to 400 khz scl) are supported. 2.1.1 iic arbitration and control logic in the master transmitter mode, the arbitration logic checks that every transmitted logic ??actually appears as a logic 1 on the i 2 c bus. if another device on the bus overrules a logic ??and pulls the sda line low, arbitration is lost and the iic module immediately changes from master transmitter to slave receiver. the iic module will continue to output clock pulses (on scl) until transmission of the current serial byte is complete. arbitration may also be lost in the master receiver mode. loss of arbitration in this mode can only occur while the iic module is returning a ?ot acknowledge (logic ?? to the bus. arbitration is lost when another device on the bus pulls this signal low. since this can occur only at the end of a serial byte, the iic module generates no further clock pulses. the synchronization logic will synchronize the serial clock generator with the clock pulses on the scl line from another device. if two or more master devices generate clock pulses, the ?ark?(high level) duration is determined by the device that generates the shortest marks, and the ?pace?(low level) duration is determined by the device that generates the longest spaces.
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-3 a slave may stretch the space duration to slow down the bus master. the space duration may also be stretched for handshaking purposes. this can be done after each bit or after a complete byte transfer. the iic module will stretch the scl space duration after a byte has been transmitted or received and the acknowledge bit has been transferred. this block also controls all of the signals for serial byte handling. it provides the shift pulses for dat, enables the comparator, generates and detects start and stop conditions, receives and transmits acknowledge bits, controls the master and slave modes, contains interrupt request logic and monitors the i 2 c bus status. 2.1.2 serial clock generator this programmable clock pulse generator provides the scl clock pulses when the iic module is in master transmitter or master receiver mode. it is switched off when the iic module is in a slave mode. the output frequency is dependent on the cr bits in the control register. the output clock pulses have a 50% duty cycle unless the clock generator is synchronized with other scl clock sources, as described above. 2.1.3 bit counter the bit counter tracks the number of bits that have been received during the byte transfer. the output from this counter is used to trigger events, such as address recognition and acknowledge generation, which occur at speci? points during the byte transfer. 2.1.4 control register this register is used by the micro controller to control the generation of start and stop conditions, enable the interface, control the generation of acks, and to select the clock frequency. 2.1.5 status decoder and register there are 26 possible bus states if all four modes of the iic module are used. the status decoder takes all of the internal status bits and compresses them into a 5-bit code. this code is unique for each i 2 c bus status. the 5-bit code may be used for processing the various service routines. each service routine processes a particular bus status. the 5-bit status code is stored in bits 7-3 of the status register. bits 2-0 and 31-8 of the status register are always zero. 2.1.6 input filter input signals sda and scl from io pad cells are synchronized with the internal clock. spikes shorter than three clock periods are ?tered out. 2.1.7 address register and comparator this sfr may be loaded with the 7-bit slave address to which iic module will respond when programmed as a slave. the least signi?ant bit is used to enable the general call address recognition. the comparator compares the received 7-bit slave address with its own slave address. it also compares the ?st received 8-bit byte with the general call address. if an equality is found, the appropriate status bits are set and an interrupt is requested.
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-4 2.1.8 data shift register this register contains a byte of serial data to be transmitted or a byte which has just been received. like all the registers in this module, only bits 7-0 are used. data in dat is always shifted from right to left; the ?st bit to be transmitted is the msb (bit 7) and, after a byte has been received, the ?st bit of received data is located at the msb (bit 7) of dat. while data is being shifted out, data on the bus is simultaneously being shifted in; dat always contains the last byte present on the bus. thus, in the event of lost arbitration, the transition from master transmitter to slave receiver is made with the correct data in dat. 2.1.9 related interrupts the serial interrupt signal (iic_intrn) issues an interrupt when any one of the 26 possible iic module states are entered. the only state that never causes an interrupt is state 0xf8, which indicates that no relevant state information is available. 2.1.10 modes of operation the iic module hardware may operate in any of the following four modes: master transmitter master receiver slave receiver slave transmitter as a master, the iic module will generate all the serial clock pulses and the start and stop conditions. a transfer ends with a stop condition or with a repeated start condition. since a repeated start condition is also the beginning of the next serial transfer, the i 2 c bus will not be released. two types of data transfers are possible on the i 2 c bus: data transfer from a master transmitter to a slave receiver. the ?st byte transmitted by the master is the slave address. next follows a number of data bytes. the slave returns an acknowledge bit after each received byte. data transfer from a slave transmitter to a master receiver. the ?st byte (the slave address) is transmitted by the master. the slave then returns an acknowledge bit. next follows the data bytes transmitted by the slave to the master. the master returns an acknowledge bit after each received byte except the last byte. at the end of the last received byte, a ?ot acknowledge is returned. in a given application, the iic module may operate as a master and as a slave. in the slave mode, the iic module hardware looks for its own slave address and the general call address. if one of these addresses is detected, an interrupt is requested. when the micro controller wishes to become the bus master, the hardware waits until the bus is free before the master mode is entered so that a possible slave action is not interrupted. if bus arbitration is lost in the master mode, the iic module switches to the slave mode immediately and can detect its own slave address in the same serial transfer.
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-5 master transmitter mode serial data is output through sda while scl outputs the serial clock. the ?st byte transmitted contains the slave address of the receiving device (7-bit sla) and the data direction bit as in figure 1 . in this case the data direction bit (r/w) will be a logic ??(w). serial data is transmitted 8 bits at a time. after each byte is transmitted, an acknowledge bit is received. start and stop conditions are output to indicate the beginning and end of a serial transfer. in the master transmitter mode, a number of data bytes can be transmitted to the slave receiver. before the master transmitter mode can be entered, the iic_control register must be initialized with the en bit set and the sta and sto bits reset. en must be set to enable the iic module interface. if the aa bit is reset, the iic module will not acknowledge its own slave address or the general call address if they are present on the bus. this will prevent the iic module interface from entering a slave mode. the master transmitter mode may now be entered by setting the sta bit. the iic module will then test the i 2 c bus and generate a start condition as soon as the bus becomes free. when a start condition is transmitted, the status code in the status register (sta) will be 0x08. this status code must be used to vector to an interrupt service routine that loads iic_dat with the slave address and the data direction bit (sla+w). when the slave address and direction bit have been transmitted and an acknowledgment bit has been received, a number of status codes in sta are possible. the appropriate action to be taken for any of the status codes is detailed in t ab le 5 on page 25- 11 . after a repeated start condition (state 0x10), the iic module may switch to the master receiver mode by loading iic_dat with sla+r. master receiver mode the ?st byte transmitted contains the slave address of the transmitting device (7-bit sla) and the data direction bit. in this case, the data direction bit (r/w) will be logic 1 (r). serial data is received via sda while scl outputs the serial clock. serial data is received 8 bits at a time. after each byte is received, an acknowledge bit is transmitted. start and stop conditions are output to indicate the beginning and end of a serial transfer. in the master receiver mode, a number of data bytes are received from a slave transmitter. the transfer is initialized as in the master transmitter mode. when the start condition has been transmitted, the interrupt service routine must load iic_dat with the 7-bit slave address and the data direction bit (sla+r). figure 1: sda first transmitted byte 7-bit sla r/w 7 10
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-6 when the slave address and data direction bit have been transmitted and an acknowledgment bit has been received, a number of status codes are possible in sta. the appropriate action to be taken for each of the status codes is detailed in t ab le 5 . after a repeated start condition (state 0x10), the iic module may switch to the master transmitter mode by loading iic_dat with sla+w. slave receiver mode serial data and the serial clock are received through sda and scl. after each byte is received, an acknowledge bit is transmitted. start and stop conditions are recognized as the beginning and end of a serial transfer. address recognition is performed by hardware after reception of the slave address and direction bit. in the slave receiver mode, a number of data bytes are received from a master transmitter. to initiate the slave receiver mode, iic_address must be loaded with the 7-bit slave address to which the iic module will respond when addressed by a master. also the least signi?ant bit of iic_address should be set if the interface should respond to the general call address (0x00). the iic_control register, should be initialized with en and aa set and sta and sto reset in order to enter the slave receiver mode. setting the aa bit will enable the logic to acknowledge its own slave address or the general call address and en will enable the interface. when iic_address and iic_control have been initialized, the iic module waits until it is addressed by its own slave address, followed by the data direction bit which must be ? (w) for the iic module to operate in the slave receiver mode. after its own slave address and the w bit have been received, a valid status code can be read from iic_dat. this status code should be used to vector to an interrupt service routine. the appropriate action to be taken for each of the status codes is detailed in t ab le 5 . the slave receiver mode may also be entered if arbitration is lost while the iic module is in the master mode. if the aa bit is reset during a transfer, the iic module will return a not acknowledge (logic ?? to sda after the next received data byte. while aa is reset, the iic module does not respond to its own slave address or a general call address. however, the i 2 c bus is still monitored and address recognition may be resumed at any time by setting aa. this means that the aa bit may be used to isolate the iic module from the i 2 c bus temporarily. slave transmitter mode the ?st byte is received and handled as in the slave receiver mode. however, in this mode, the direction bit will indicate that the transfer direction is reversed. serial data is transmitted via sda while the serial clock is input through scl. start and stop conditions are recognized as the beginning and end of a serial transfer. in the slave transmitter mode, a number of data bytes are transmitted to a master receiver. data transfer is initialized as in the slave receiver mode. when iic_address and iic_control have been initialized, the iic module waits until it is addressed by its own slave address followed by the data direction bit, which must be ??(r) for the iic module to operate in the slave transmitter mode. after its own slave address and the r bit have been received, a valid status code can be read from sta. this status code is used to vector to an interrupt service routine. the
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-7 appropriate action to be taken for each of these status codes is detailed in the t ab le 5 . the slave transmitter mode may also be entered if arbitration is lost while the iic module is in the master mode. if the aa bit is reset during a transfer, the iic module will transmit the last byte of the transfer and enter state 0xc0 or 0xc8. the iic module is switched to the ?ot addressed slave mode and will ignore the master receiver if it continues the transfer. thus the master receiver receives all 1s as serial data. while aa is reset, the iic module does not respond to its own slave address or a general call address. however, the i 2 c bus is still monitored and address recognition may be resumed at any time by setting aa. this means that the aa bit may be used to temporarily isolate the iic module from the i 2 c bus. 3. register descriptions table 1: register summary offset symbol description 0x04 5000 i2c_control controls the operation mode of the iic module 0x04 5004 i2c_dat byte of data to be transmitted or received 0x04 5008 i2c_status indicates the status of the iic module 0x04 500c i2c_address slave address of the iic module 0x04 5010 i2c_stop set sto ?g 0x04 5014 i2c_pd powerdown, reset iic sampling clock registers except for mmio registers 0x04 5018 i2c_set_pins set i 2 c bus sda and/or scl signals low 0x04 501c i2c_obs_pins observe i 2 c bus sda and scl signals 0x04 5020 9fdc reserved 0x04 5fe0 i2c_int_status interrupt status register 0x04 5fe4 i2c_int_en interrupt enable register 0x04 5fe8 i2c_int_clr interrupt clear register 0x04 5fec i2c_int_set interrupt software set register 0x04 5ff0 reserved 0x04 5ff4 i2c powerdown powerdown mode, switch module clock off 0x04 5ff8 reserved 0x04 5ffc module id module identi?ation and revision information
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-8 3.1 register tables bit 7: aa address acknowledge if the aa ?g is set, an acknowledge (low level to sda) will be returned during the acknowledge clock pulse on the scl line when: the ?wn slave address?has been received. the general call address has been received while the general call bit (gc) in the adr register is set. a data byte has been received while iic module is in the master receiver mode. a data byte has been received while iic module is in the addressed slave receiver mode. table 2: iic registers bit symbol acces s value description offset 0x04 5000 i2c control 31:8 unused - ignore upon read. write as zeroes. 7 aa r/w 0 iic acknowledge bit 0 = acknowledge not returned during acknowledge clock pulse 1 = acknowledge returned during acknowledge clock pulse 6 en r/w 0 iic enable bit 0 = disable iic module 1 = enable iic module 5 sta r/w 0 iic start bit 0 = slave mode, accept transactions 1 = master mode, generate start condition if bus is free 4 sto r 0 iic stop bit 0 = slave mode, accept transactions 1 = generate stop condition on i 2 c bus when iic module is master. 3 unused - ignore upon read. write as zeroes. 2:0 cr r/w 100 these three bits determine the serial clock frequency when iic module is in master mode. this ?ld shall be changed only when en bit is 0. the iic clock is divided as follows to achieve the desired frequency. the table assumes the iic module receives a 24 mhz clock from the clock module. 0: 60 -> 400 khz 1: 80 -> 300 khz 2: 120 -> 200 khz 3: 160 -> 150 khz 4: 240 -> 100 khz 5: 320 -> 75 khz 6: 480 -> 50 khz 7: 960 -> 25 khz
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-9 if the aa ?g is cleared and the iic-bus module is in the addressed slave transmitter mode, state 0xc8 will be entered after the last serial bit is transmitted. the iic module leaves state 0xc8, enters the ?ot addressed?slave receiver mode, and the sda line remains at a high level. in state 0xc8, the aa ?g can be set again for future address recognition. if the aa ?g is cleared and the iic module is in the ?ot addressed?slave mode, its own slave address and the general call address are ignored. consequently, no acknowledge is returned, and a serial interrupt is not requested. thus, iic module can be temporarily released from the i 2 c bus while the bus status is monitored. while the iic module is released from the bus, start and stop conditions are detected, and serial data is shifted in. address recognition can be resumed at any time by setting the aa ?g. if the aa ?g is set when the parts own slave address or the general call address has been partly received, the address will be recognized at the end of the byte transmission. bit 6: en enable when en is ?? the sda and scl outputs are constantly at 1 level leading to a high impedance state at the associated port lines sda and scl. the state of the sda and scl input lines are ignored; iic module is in the ?ot addressed?slave state, and the sto bit in iic_control is forced to ?? no other bits are affected. sda and scl port lines may be used as open drain i/o ports. when en is ?? iic module is enabled. the port latches associated to sda and scl must be set to logic 1. en should not be used to temporarily release iic module from the i 2 c bus because when en is reset, the i 2 c bus status is lost. the aa ?g should be used to temporarily release the iic module. bit 5: sta start bit when the sta bit is set to enter a master mode, the iic module hardware checks the status of the i 2 c bus and generates a start condition if the bus is free. if it is not free, the iic module waits for a stop condition (which will free the bus) and generates a start condition after a delay of a low clock period in the internal serial clock generator. if sta is set while iic module is already in master mode and one or more bytes are transmitted or received, the iic module transmits a repeated start condition. sta may be set at any time. it may also be set when the iic module is an addressed slave. when the sta bit is reset, no start condition or repeated start condition will be generated. bit 4: sto stop bit a write to iic_control register will not affect this bit. it must be written via iic_stop register. when the sto bit is set while iic module is in a master mode, a stop condition is transmitted to the i 2 c bus.
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-10 when the stop condition is detected on the bus, the iic module hardware clears the sto ?g. in a slave mode, the sto ?g may be set to recover from an error condition. in this case, no stop condition is transmitted to the i 2 c bus. however, the iic module hardware behaves as if a stop condition has been received and switches to the de?ed ?ot addressed?slave receiver mode. the sto ?g is automatically cleared by the hardware. if the sta and sto bits are both set, the stop condition is transmitted to the i 2 cbus if iic module is in master mode. in slave mode, the iic module generates an internal stop condition, which is not transmitted. it then transmits a start condition. when the sto bit is reset, no stop condition will be generated. there is also no interrupt generated for detection of a stop condition which was created by the iic. (the iic needs to be in master mode to do this). and there is no status code for this condition in the iic status register. bits [2:0]: cr for details, see bits[2:0] in offset 0x04 5000 i2c contr ol of the register table. bit [7:0]: dat dat contains a byte of serial data to be transmitted or a byte which has just been received. this special function register can be read from or written to while it is not in the process of shifting a byte. this occurs when iic module is in a de?ed state. data in dat is always shifted from right to left: the ?st bit to be transmitted is the msb (bit 7), and after a byte has been received, the ?st bit of received data is located at the msb of dat. while data is being shifted out, data on the bus is simultaneously being shifted in; dat always contains the last data byte present on the bus. thus, in the event of lost arbitration, the transition from master transmitter to slave receiver is made with the correct data in dat. reset initializes dat to 0x00. a logic ??in dat corresponds to a high level on the i 2 c bus, and a logic ? corresponds to a low level on the bus. serial data shifts through dat from right to left. dat and the ack ?g form a 9-bit shift register which shifts in or shifts out 8 bits, followed by an acknowledge bit. the ack ?g is controlled by the iic module hardware and cannot be accessed by the cpu. serial data is shifted through the ack ?g into dat on the rising edges of clock pulses on the scl line. when a byte has been shifted into dat, the serial data is available in dat, and the acknowledge bit is returned by the control logic during the 9th clock pulse. serial data is shifted out from dat via a buffer on the falling edges of clock pulses on the scl line. table 3: iic registers bit symbol acces s value description offset 0x04 5004 i2c data register 31:8 unused - ignore upon read. write as zeroes. 7:0 dat r/w 0 write byte data to be transmitted on the i2c bus. read byte data has been received from the i2c bus.
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-11 when the cpu writes to dat, the buffer is loaded with the contents of dat(7) which is the ?st bit to be transmitted to the sda line. after nine serial clock pulses, the eight bits in dat will have been transmitted to the sda line, and the acknowledge bit will be present in ack. note that the eight transmitted bits are shifted back into dat. bit [7:3]: sta status register sta is a read-only special function register. writing to this register has no affect. the three least signi?ant bits are always zero. the bits 7-3 contain the status code. there are 26 possible status codes. when sta contains 0xf8, no relevant state information is available and no serial interrupt is requested. reset initializes sta to 0xf8. all other sta values correspond to de?ed iic module states. see the last row of t ab le 5 for an explanation of the terms used. table 4: iic registers bit symbol acces s value description offset 0x04 5008 i2c status register 31:8 unused - ignore upon read. write as zeroes. 7:3 sta r 0 indicates the status of the iic module. 2:0 unused - ignore upon read. write as zeroes. table 5: status codes status code sta bus/module status application software response next action taken to/from dat to con sta sto si aa 0x00 bus error no dat action 0 1 0 x hw will enter the ?ot addressed?slave mode. 0x08 a start condition has been transmitted load sla+w x 0 0 x sla+w will be transmitted, ack bit will be received (i 2 c bus module will be switched to mst/trx mode). load sla+r x 0 0 x sla+r will be transmitted, ack bit will be received (i 2 c bus module will be switched to mst/rec mode). 0x10 a repeated start condition has been transmitted load sla+w x 0 0 x sla+w will be transmitted, ack bit will be received (i 2 c bus module will be switched to mst/trx mode). load sla+r x 0 0 x sla+r will be transmitted, ack bit will be received (i 2 c bus module will be switched to mst/rec mode). 0x18 sla+w has been transmitted; ack has been received load data byte 0 0 0 x data byte will be transmitted; ack bit will be received. no dat action 1 0 0 x repeat start will be transmitted no dat action 0 1 0 x stop condition will be transmitted; stop ?g will be reset. no dat action 1 1 0 x stop condition followed by a start condition will be transmitted; sto ?g will be reset.
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-12 0x20 sla+w has been transmitted; not ack has been received load data byte 0 0 0 x data byte will be transmitted; ack bit will be received. no dat action 1 0 0 x repeat start will be transmitted. no dat action 0 1 0 x stop condition will be transmitted; stop ?g will be reset. no dat action 1 1 0 x stop condition followed by a start condition will be transmitted; sto ?g will be reset. 0x28 data byte in dat has been transmitted; ack has been received load data byte 0 0 0 x data byte will be transmitted; ack bit will be received no dat action 1 0 0 x repeat start will be transmitted. no dat action 0 1 0 x stop condition will be transmitted; stop ?g will be reset. no dat action 1 1 0 x stop condition followed by a start condition will be transmitted; sto ?g will be reset. 0x30 data byte in dat has been transmitted; not ack has been received load data byte 0 0 0 x data byte will be transmitted; ack bit will be received. no dat action 1 0 0 x repeat start will be transmitted. no dat action 0 1 0 x stop condition will be transmitted; stop ?g will be reset. no dat action 1 1 0 x stop condition followed by a start condition will be transmitted; sto ?g will be reset. 0x38 arbitration lost in the sla+r/w or data bytes no dat action 0 0 0 x i 2 c bus will be released; the ?ot addressed?slave mode will be entered. no dat action 1 0 0 x a start condition will be transmitted when the bus becomes free. 0x40 sla+r has been transmitted; ack has been received no dat action 0 0 0 0 data byte will be received; not ack bit will be returned. no dat action 0 0 0 1 data byte will be received; ack bit will be returned 0x48 sla+r has been transmitted; not ack has been received no dat action 1 0 0 x repeated start condition will be transmitted no dat action 0 1 0 x stop condition will be transmitted; sto ?g will be reset. no dat action 1 1 0 x stop condition followed by a start condition will be transmitted; sto ?g will be reset. 0x50 data byte has been received; ack has been returned read data byte 0 0 0 0 data byte will be received; not ack bit will also been returned. read data byte 0 0 0 1 data byte will be received; ack bit will be returned. table 5: status codes ?ontinued status code sta bus/module status application software response next action taken to/from dat to con sta sto si aa
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-13 0x58 data byte has been received; not ack has been returned read data byte 1 0 0 x repeated start condition will be transmitted. read data byte 0 1 0 x stop condition will be transmitted; sto ?g will be reset. read data byte 1 1 0 x stop condition followed by a start condition will be transmitted; sto bit will be reset. 0x60 own sla+w has been received; ack has been returned no sta action x 0 0 0 data byte will be received and not ack will be returned. no sta action x 0 0 1 data byte will be received and ack will be returned. 0x68 arbitration lost in sla+r/w as master; own sla+w has been received; ack has been returned no sta action x 0 0 0 data byte will be received and not ack will be returned. no sta action x 0 0 1 data byte will be received and ack will be returned. 0x70 general call address (00h) has been received; ack has been returned no sta action x 0 0 0 data byte will be received and not ack will be returned. no sta action x 0 0 1 data byte will be received and ack will be returned. 0x78 arbitration lost in sla+r/w as master; general call address has been received; ack has been returned no sta action x 0 0 0 data byte will be received and not ack will be returned. no sta action x 0 0 1 data byte will be received and ack will be returned. 0x80 previously addressed with own sla; data byte has been received; ack has been returned no sta action x 0 0 0 data byte will be received and not ack will be returned. no sta action x 0 0 1 data byte will be received and ack will be returned. table 5: status codes ?ontinued status code sta bus/module status application software response next action taken to/from dat to con sta sto si aa
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-14 0x88 previously addressed with own sla; data byte has been received; not ack has been returned read data byte 0 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. read data byte 0 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? read data byte 1 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. a start condition will be transmitted when bus becomes free. read data byte 1 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? a start condition will be transmitted when the bus becomes free. 0x90 previously addressed with general call; data byte has been received; ack has been returned read data byte x 0 0 0 data byte will be received and not ack will be returned. read data byte x 0 0 1 data byte will be received and ack will be returned. 0x98 previously addressed with general call; data byte has been received; not ack has been returned read data byte 0 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. read data byte 0 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? read data byte 1 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. a start condition will be transmitted when the bus becomes free. read data byte 1 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? a start condition will be transmitted when the bus becomes free. table 5: status codes ?ontinued status code sta bus/module status application software response next action taken to/from dat to con sta sto si aa
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-15 0xa0 a stop condition or repeated start condition has been received while still addressed as slv/ (rec or trx) (but for slv/trx a violation of i 2 cbus format) no sta action 0 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. no sta action 0 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? no sta action 1 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. a start condition will be transmitted when the bus becomes free. no sta action 1 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? a start condition will be transmitted when the bus becomes free. 0xa8 own sla+r has been received; ack has been returned load data byte x 0 0 0 last data byte will be transmitted and ack bit will be received. load data byte x 0 0 1 data byte will be transmitted; ack bit will be received. 0xb0 arbitration lost in sla+r/w as master; own sla+r has been received; ack has been received load data byte x 0 0 0 last data byte will be transmitted and ack bit will be received. load data byte x 0 0 1 data byte will be transmitted; ack bit will be received. 0xb8 data byte in dat has been transmitted; ack has been received load data byte x 0 0 0 last data byte will be transmitted and ack bit will be received. load data byte x 0 0 1 data byte will be transmitted; ack bit will be received. 0xc0 data byte in dat has been transmitted; not ack has been received (aa = x) no sta action 0 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. no sta action 0 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? no sta action 1 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. a start condition will be transmitted when the bus becomes free. no sta action 1 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? a start condition will be transmitted when the bus becomes free. table 5: status codes ?ontinued status code sta bus/module status application software response next action taken to/from dat to con sta sto si aa
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-16 bit [7:1]: slave_addr slave address slave_addr is not affected by the iic module hardware. the contents of this register are irrelevant when iic module is in a master mode. in the slave mode, the bits 7:1 must be loaded with the micro controllers own slave address. these bits correspond to the 7-bit slave address which will be recognized on the incoming data stream from the i 2 c bus. when the slave address is detected and the interface is enabled, a serial interrupt will be generated. bit 0: gen_call_addr general call address when this bit is set, the general call address (slave address[7:1] on i 2 c bus = 0x00, r/w bit on i 2 c bus = 0) is recognized. if not set, this bit is ignored. 0xc8 last data byte in dat has been transmitted (aa = 0); ack has been received no sta action 0 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. no sta action 0 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? no sta action 1 0 0 0 switched to ?ot addressed?slv mode; no recognition of own sla or general call address. a start condition will be transmitted when the bus becomes free. no sta action 1 0 0 1 switched to ?ot addressed?slv mode; own sla will be recognized; general call address will be recognized if adr(0) =?? a start condition will be transmitted when the bus becomes free. 0xf8 no information available no dat action no iic_control action wait or proceed with current transfer. mst?aster slv?lave rec?eceiver trx?ransmitter sla?lave address w?rite bit r?ead bit x?on? care bit table 6: iic registers bit symbol acces s value description offset 0x04 500c i2c address register 31:8 unused - ignore upon read. write as zeroes. 7:1 slave_addr r/w 0x00 slave address when in slave mode 0 gen_call_addr r/w 0x0 general call address 0 = does not generate interrupt if general call address is detected on the i 2 c bus. 1= generates interrupt if general call address is detected. table 5: status codes ?ontinued status code sta bus/module status application software response next action taken to/from dat to con sta sto si aa
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-17 table 7: iic registers bit acces s value symbol description offset 0x04 5010 i2c stop register 31:1 - unused ignore upon read. write as zeroes. 0 r/w 0 sto set and read sto ?g writes: in master mode, set sto ?g to indicate a stop has been requested. then generate a stop condition on i 2 c bus. when the stop condition is detected on the bus, the iic module hardware clears the sto flag. in slave mode, set sto ?g to indicate a stop has been requested. no stop condition is transmitted to the i 2 c bus. however, the iic module hardware behaves as if a stop condition has been received and switches to the defined ?ot addressed slave receiver mode. the sto flag is immediately cleared by the hardware so that software can never see it set. reads: view the sto ?g to see if a stop has been requested. sto ?g can also be viewed by reading the sto bit of iic_control. see sto bit of iic_control register for more information offset 0x04 5014 i2c pd register 31:3 - unused ignore upon read. write as zeroes. 2 r/w 0 pd this bit synchronously resets the iic clock domain except for the mmio registers. 0 = don? reset iic clock domain. 1 = reset iic clock domain. note: do not reset the iic clock domain until the iic module is disabled using bit 6 of the iic control register. 1:0 - unused ignore upon read. write as zeroes. offset 0x04 5018 i2c bus set register 31:2 - unused ignore upon read. write as zeroes. 1 w 0 set_scl_low pull i2c scl bus signal to logic one or zero: 1 = pulls scl signal to logic zero. 0 = scl signal is not pulled to logic zero. 0 w 0 set_sda_low pull i2c sda bus signal to logic one or zero: 1 = pulls sda signal to logic zero. 0 = sda signal is not pulled to logic zero. offset 0x04 501c i2c bus observation register 31:2 - unused ignore upon read. write as zeroes. 1 r 0 observe_scl observe i2c scl bus signal: 1 = scl signal is at logic one. 0 = scl signal is at logic zero. 0 r 0 observe_sda observe i2c sda bus signal 1 = sda signal is at logic one. 0 = sda signal is at logic zero. offset 0x04 5020?fdc reserved
philips semiconductors pnx15xx series volume 1 of 1 chapter 25: i 2 c interface 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 25-18 offset 0x04 5fe0 i2c interrupt status register 31:1 - unused ignore upon read. write as zeroes. 0 r 0 int_status interrupt status register. it reports any pending interrupts: 1 = interrupt i pending. 0 = interrupt i not pending. offset 0x04 5fe4 i2c interrupt enable register 31:1 - unused ignore upon read. write as zeroes. 0 r/w 0 int_enable interrupt enable register 1 = interrupt i is enabled. 0 = interrupt is disabled. offset 0x04 5fe8 i2c interrupt clear register 31:1 - unused ignore upon read. write as zeroes. 0 w 0 int_clear interrupt clear register. 1 = interrupt is cleared. 0 = interrupt is not cleared. note: the iic module will look at a new transaction on the i 2 c bus as soon as the previous interrupt has been cleared. therefore, software must make sure that ?nterrupt clear is the last transaction that is sent to the iic module before starting a new transaction. offset 0x04 5fec i2c interrupt set register 31:1 - unused ignore upon read. write as zeroes. 0 w 0 int_set interrupt set register. allows software to set interrupts. 1 = interrupt is set 0 = interrupt is not set. offset 0x04 5ff0 reserved offset 0x04 5ff4 i2c powerdown register 31 r/w 0 power_down 0 = normal operation of peripheral. this is the reset value. 1 = module is powerdown and module clock can be removed. module returns deadabba on all reads except for reads of the powerdown bit. module generates err ack on all writes except for writes to the powerdown bit. 30:0 - unused ignore upon read. write as zeroes. offset 0x04 5ff8 reserved offset 0x04 5ffc i2c module id register 31:16 r 0x0105 module id unique 16-bit code. module id 15:12 r 0x0 majrev major revision 11:8 r 0x3 minrev minor revision 7:0 r 0x00 module aperture size aperture size = 4 kb*(bit_value+1), so 0 means 4 kb (the default). table 7: iic registers ?ontinued bit acces s value symbol description
1. introduction all the memory traf? of pnx15xx series modules is centralized into an internal hub, through the mtl bus, before it gets to the main memory interface module. in addition to this network function, the hub includes a generic arbiter for memory bandwidth allocation. remark: the arbiter only deals with module memory traffic and not with cpu memory traffic which is handled by the main memory interface module, see c h a p t e r 9 d d r controller . this is different approach than the pnx1300 series arbiter. 1.1 features the key features of the hub are: provides a hierarchical memory access network that connects module dma ports to a single access port of the main memory interface. dma agents, i.e. the pnx15xx series modules are organized in clusters. includes simple round-robin sub-arbitration for lower levels of hierarchy provides sophisticated intermediate arbitration for upper levels of the network hierarchy default settings allow each module to have access to the memory but may not ? latency requirement as soon as many modules are turned on simultaneously 2. functional description the arbiter module is used as an arbiter between different dma channel clusters. inside these clusters traf? from related dma channels of peripherals are combined by applying round-robin arbitration. (see t ab le 1 for a list of clusters and sub- arbitrated dma channels). the arbitration engine combines time-division multiple access (tdma), priority, and round-robin methods; resulting in a guaranteed and high-level quality of service. the arbitration engine ensures programmable maximum latency and programmable minimal bandwidth to the uni?d resource. it also makes sure that best effort agents are fairly granted when higher priority agents do not request the channel. the priority table can be dynamically altered by software. two priority tables are implemented from which the inactive table can be changed on-the-?. the arbiter hardware takes care of smooth switching between the two tables. chapter 26: memory arbiter pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-2 after reset, the arbiter is in ?oot mode and guarantees that each requesting agent is given a ?rant?to main memory (round robin is the default arbitration method). 2.1 arbiter features time-division multiple access (tdma) arbitration guarantees maximum allowed latency 128 tdma slots priority arbitration guarantees minimum required bandwidth 16 priority slots two level round robin arbitration provides equal opportunities to the lower priority ?est effort?or dma write agents 16 round robin slots in the ?st level 8 round robin slots in the second level dynamic arbitration scheme two sets of arbitration parameters can be de?ed. selection can be made dynamically via software based on system needs. 2.2 id mapping the t ab le 1 shows the mapping of each module to an unique identi?ation numbers. the ?st column shows the ids when programing the tdma wheel. the second column indicates which id number to use when programing the priority and roundrobin list. t ab le 1 also shows the amount of sub-arbitration for the given modules. if not otherwise noted the amount of buffering per dma channel is 256 bytes. table 1: peripheral id and sub-arbitration tdma id id modules dma channels buffer size transaction size 0x8 0x0 2dde 1 x r, 1 x w 2 x 256-byte buffer 128 bytes 0x9 0x1 pci 2 x r, 2 x w 4 x 256-byte buffer 128 bytes 0xa 0x1 qvcp 4 x r 4 x 512-byte buffer 128 bytes 0xb 0x3 vip 3 x w 3 x 256-byte buffer 128 bytes 0xc 0x4 vld 1 x r, 2 x w 3 x 256-byte buffer 128 bytes 0xd 0x5 fgpi 2 x w 2 x 512-byte buffer 128 bytes 0xe 0x6 reserved 0xf 0x7 mbs (r) 3 x r 3 x 256-byte buffer 128 bytes 0x0 0x8 mbs (w) 3 x w 3 x 256-byte buffer 128 bytes 0x1 0x9 10/100 mac 2 r x 3 w 10 x 32-byte buffer 32 bytes 0x2 0xa fgpo 2 x r 4 x 256-byte buffer 1 x 16-byte buffer 128 bytes
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-3 2.2.1 dcs gate the dcs gate is a simple connection between the dcs bus and the hub. any 32-bit write transaction that is in the range of dcs_dram_lo to dcs_dram_hi causes a write transaction to main memory via the dcs gate. this is provided for booting pnx15xx series from eeprom. the dcs_dram_lo and dcs_dram_hi registers are located in the global registers; see chapter 3 system on chip resources and figure 3 on page 3- 30 for a simpli?d block diagram of pnx15xx series. 2.3 arbitration algorithm one of the most important purposes of the arbiter is to guarantee a high level of quality of service to the dma agents (pnx15xx series modules). in technical terms this means: the ability to guarantee a programmable maximum latency to dma agents the ability to guarantee a programmable amount of bandwidth to dma agents the ability to provide equal opportunity to dma agents any (complex) combination of the three mechanisms mentioned above the arbiter is not optimized to process requests for memory access from cpus. typically the performance of cpus depends directly on the access latency to memory and for this reason they require the lowest possible memory latency. to realize this cpus can best get their performance requirements via a private port on a multi-port memory controller. therefore, the cpus are not connected to the arbiter and do not route memory requests via the hub. to support the quality of service features as mentioned above the arbiter algorithm consists of a combination of three basic arbitration mechanisms. these are: time-division multiple access (tdma) arbitration to guarantee maximum latency priority arbitration to guarantee bandwidth to reading s oft real time dma ( srt dma) agents round-robin arbitration to guarantee bandwidth to writing srt dma agents round-robin arbitration to provide equal opportunity for best effort (be) dma agents 0x3 0xb spdi/o, ai/o, gpio (r,w) 3 x r, 3 x w 2 x 128-byte buffer 64 bytes 0x4 0xc dvdd 1 x r, 1 x w 2 x 256-byte buffer 128 bytes 0x5 0xd dcs gate 1 x w 2 x 32-bit buffer 8 bytes 0x6:0x7 0xe:0xf reserved table 1: peripheral id and sub-arbitration ?ontinued tdma id id modules dma channels buffer size transaction size
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-4 the combination of these three basic algorithms operate together in the arbiter as shown in figure 1 . the tdma timing wheel is implemented with 128 entries, numbered 1 to 128. the tdma_entries ?ld in the nr_entries_a 1 register will determine the actual number of entries that are used. tdma entries higher than this value will be ignored. if the tdma_entries is greater than 128 then all 128 entries are used, but no more. if tdma_entries is set to zero then the tdma timing wheel is not used for arbitration. the priority list is implemented with 16 entries, numbered 1 to 16. the priority_entries ?ld in the nr_entries_a register will determine the actual number of entries that are used. if a value greater than 16 is written all 16 entries are used, but no more. if the priority_entries is set to zero then the priority list is not used for arbitration. the round robin #1 list is implemented with 16 entries, numbered 1 to 16. the round_robin1_entries ?ld in the nr_entries_a register will determine the actual number of entries that are used. if a value greater than 16 is written all 16 entries are used, but no more. if the round_robin1_entries is set to zero then the round robin #1 list is not used for arbitration. the round robin #2 list is implemented with 8 entries, numbered 1 to 8. the round_robin2_entries ?ld in the nr_entries_a register will determine the actual number of entries that are used. if a value greater than 8 is written all 8 entries are used, but no more. if the round_robin2_entries is set to zero then the round robin #2 list is not used for arbitration. figure 1: arbitration scheme 1. all references to ?et a?registers also apply equally to ?et b? tdma timing wheel priority list high low round robin #2 overall priority highest lowest round robin #1
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-5 assuming the arbiter has been con?ured to include the priority list and both round- robin lists, any arbiter decision is made through the following four steps: 1. first the dma requests are compared against the current entry in the tdma timing wheel. if the agent in the current entry is requesting this agent will be granted. 2. if the agent in the current entry is not requesting the dma requests will be compared against the agents in the priority list and if one or more of the agents in the priority list is requesting the one that has the highest priority will be granted. 3. if none of the dma requests matches the current entry in the tdma timing wheel or one or more entries in the priority list, the arbiter will grant the dma agent that has not been served for the longest time by choosing from the round robin #1 list. every time the arbiter provides a grant to any dma agent, the round robin #1 arbiter checks if this agent is in its list and makes that agent the lowest priority entry in the round robin #1 list. if a certain agent is granted because of its entry in the tdma timing wheel or priority list and the same agent has also an entry in the round-robin #1 list, then in the next clock cycle this agent will have the lowest priority in the round-robin #1 list. also, in case there are multiple entries of the same agent in the round-robin #1 list, the highest entry in the list gets the lowest priority during the next cycle. the other entries of the same agents do not get the lowest priority. 4. if none of the dma requests matches: the current entry in the tdma timing wheel, or one or more entries in the priority list or one or more entries in the ?st round-robin list, the arbiter will grant the dma agent that has not been served for the longest time from the round robin #2 list of entries. the round-robin #2 list operates the same way as the round-robin #1 list but all entries in this list have a lower priority than the entries in the round-robin #1 list. the tdma wheel will proceed to the next entry if and only if one of the two following situations apply: when there is a grant at the level of the tdma wheel when there is no match in the complete list (tdma, priority and both round-robin lists) all entries in the tdma wheel, priority list and both round-robin lists are fully programmable via the dtl mmio interface of the arbiter. the same is true for the number of entries in any of these four. it is also possible to set the number of entries in the tdma wheel, priority list and/or round-robin lists to zero. this allows the user to use only one of the four mechanisms or any combination of them. in case all four are set to zero for the active set of entries, the arbiter defaults to a round-robin arbitration over all agents. the arbitration algorithm only starts after the arbiter has been properly initialized via the programming registers. following the de-assertion of a hard reset, the arbiter uses a simple counting algorithm to arbitrate between all request inputs. in this boot mode agents are granted in the order that they are internally wired.
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-6 2.3.1 arbiter startup behavior after reset is de-asserted, the arbiter is placed in boot mode. in this mode, the arbiter sequentially grants each agent access to the memory if the agent has asserted its request. after de-assertion of rst_an starting with req[0], then req[1], etc. four agents are checked in each clock cycle. this means that in the situation that only req[15] is asserted, it will take four clock cycles before the arbiter will grant this agent. in the ?st clock cycle it will check req[0] up to req[3], in the second clock cycle req[4] up to req[7], in the third clock cycle req[8] up to req[11] and the fourth clock cycle req[12] up to req[15]. the boot counter increments to next value when all agents corresponding to that count value have been serviced or when there is no request from the agents corresponding to that count value. this mode is not intended to intelligently allocate memory bandwidth. its goal is to simply make sure that all agents that request get granted. while in boot mode, it is expected that the system software will set up the arbiter via the dtl mmio port and switch to the normal operation mode. as there are two sets of con?uration registers (a and b), software should initialize one of the sets and then select the normal operation mode that corresponds to that set via a write to the arbiter control register. if necessary, the alternate set may be con?ured differently and the new con?uration may be engaged by simply writing the new mode in the arbiter control register. 3. operation 3.1 clock programming the hub operates with the memory controller clock, as well as the clocks of all the peripheral modules that connect to the hub. there is no separate clock for the hub. 3.2 register programming guidelines the default con?uration of the arbiter is to provide round robin access to all peripheral devices. this can be altered by software by programming the arbiter. once the arbiter con?uration is completed, the system should be able to operate without further change to the arbiter; however it is possible for software to change the arbiter con?uration on-the-? in order to change the minimum latency or the minimum memory bandwidth that is available to each peripheral device. remark: the active set of configuration registers (set a or set b) cannot be read by software once that set is activated. the inactive set may be safely written or read. if software needs to have access to the values within the active set, then a copy of these values should be maintained in main memory as a reference.
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-7 4. register descriptions 4.1 register table table 2: register summary offset symbol description 0x06 4000?1fc tdma a 128 entries of tdma timing wheel for set a 0x06 4200?23c priority a 16 entries of priority list for set a 0x06 4240?27c reserved 0x06 4280?2bc first round robin a 16 entries of ?st round robin list for set a 0x06 42c0?2fc reserved 0x06 4300?31c last round robin a 8 entries of last round robin list for set a 0x06 4320?3fc reserved 0x06 4400?5fc tdma b 128 entries of tdma timing wheel for set b 0x06 4600?63c priority a 16 entries of priority list for set b 0x06 4640?67c reserved 0x06 4680?6bc first round robin b 16 entries of ?st round robin list for set b 0x06 46c0?6fc reserved 0x06 4700?71c last round robin b 8 entries of last round robin list for set b 0x06 4720?7fc reserved 0x06 4800 nr entries a number of valid entries in arbitration lists for set a 0x06 4804 nr entries b number of valid entries in arbitration lists for set b 0x06 4808?8fc reserved 0x06 4900 control register to control operation mode of arbiter 0x06 4904 status register to monitor operation mode of arbiter 0x06 4908?ff8 reserved 0x06 4ffc module_id module id and revision information table 3: pman (hub) arbiter registers bit symbol acces s value description arbiter registers (set a) offset 0x06 4000?1fc entries of tdma timing wheel (set a) 31:10 reserved r 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 9:8 r/w grant r/w 0 grant on read, write or both 0x0 = grant independent whether it is a read or write 0x1, 0x2, 0x3 = reserved 7:5 reserved r 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 4:0 agent_id r/w 0 id of the agent that is identi?d by this entry (see t ab le 1 on page 26- 2 for ids).
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-8 offset 0x06 4200?23c entries of priority list (set a) note: offset 0x200 has the highest priority. this register is identical to offset 0x06 4000?1fc entr ies of tdma timing wheel (set a) . offset 0x06 4280?2bc entries of round robin list #1 (set a) this register is identical to offset 0x06 4000?1fc entr ies of tdma timing wheel (set a) . offset 0x06 4300?31c entries of round robin list #2 (set a) this register is identical to offset 0x06 4000?1fc entr ies of tdma timing wheel (set a) . arbiter registers (set b) offset 0x06 4400?5fc entries of tdma timing wheel (set b) 31:10 reserved r 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 9:8 r/w grant r/w 0 grant on read, write or both. 0x0 = grant independent whether it is a read or write 0x1, 0x2, 0x3 = reserved 7:5 reserved r 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 4:0 agent_id r/w 0 id of the agent that is identi?d by this entry. offset 0x06 4600?63f entries of priority list (set b) note: offset 0x200 has the highest priority. this register is identical to offset 0x06 4400?5fc entr ies of tdma timing wheel (set b) . offset 0x06 4680?6bc entries of round robin list #1 (set b) this register is identical to offset 0x06 4400?5fc entr ies of tdma timing wheel (set b) . offset 0x06 4700?71c entries of round robin list #2 (set b) this register is identical to offset 0x06 4400?5fc entr ies of tdma timing wheel (set b) . offset 0x06 4800 nr_entries_a (set a) 31:28 reserved r/w 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 27:24 round_robin2_entries r/w 0 number of valid entries in last round robin list #2 programming any value > 8 will result in use of the full round-robin list. 23:21 reserved r/w 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 20:16 round_robin1_entries r/w 0 number of valid entries in ?st round robin list #1 programming any value > 16 will result in use of the full round-robin list. 15:13 reserved r/w 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 12:8 priority_entries r/w 0 number of valid entries in priority list programming any value > 16 will result in use of full priority list. 7:0 tdma_entries r/w 0 number of valid entries in tdma wheel programming any value > 128 will result in use of all 128 entries. offset 0x06 4804 nr_entries_b (set b) this register is identical to offset 0x06 4800 nr_entries_a (set a) . table 3: pman (hub) arbiter registers ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 26: memory arbiter 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 26-9 offset 0x06 4900 arbiter control 31:2 reserved r/w 0 to ensure software backward compatibility, writes to unused or reserved bits should be zero and reads must be ignored. 1:0 arbiter_mode r/w 0 operational mode of the arbiter 00 = boot mode 01 = use register set a. 10 = use register set b. 11 = reserved offset 0x06 4ffc arbiter module_id 31:16 module_id r 0x1010 arbiter module id number 15:12 major_revision r 0 11:8 minor_revision r 0 7:0 aperture r 0 4 kb aperture size table 3: pman (hub) arbiter registers ?ontinued bit symbol acces s value description
1. power management mechanisms this chapter describes a standard programming model used to facilitate power management of peripheral modules. in the pnx15xx series, the primary method for reducing the power consumption of certain modules is to reduce the frequency or completely stop the clock signal to those modules. however, modules such as the cpu and the memory system have their own built-in power management mechanisms. these mechanisms are described individually in this chapter due to their uniqueness and interconnection with system-level operations and global resources. 1.1 clock management the on-chip clock module contains registers which connect/disconnect different clock sources to peripheral modules. the clock signals of most modules on the pnx15xx series can be stopped if the appropriate procedure is followed. due to wake-up logistics, however, it is not possible to completely stop the clock signals to some of the modules. 1.1.1 essential operating infrastructure during powerdown the dcs bus (also called mmio bus) clock should not be stopped directly but only using the procedure de?ed in chapter 5 the cloc k module section 27 on page 27- 1 . remark: once all the clocks have been turned off, the pci module cannot reply to any request on the pci bus. therefore it must be ensured that this condition does not arise. 1.1.2 module powerdown sequence the following sequence of events must take place for powerdown to occur: the tm3260 or an external host prepares the module for powerdown. this is achieved by disabling the module if it was active. applying a software reset is recommended. at this point, any pending device interrupts should have been handled by the cpu to ensure the device does not generate new interrupts or bus transactions when disabled. note that module registers are still fully functional. any device register can be read/written and the device can be re-enabled if desired. chapter 27: power management pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 27: power management 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 27-2 the cpu writes/sets the device's powerdown control bit (usually bit 31 of offset 0xff4). setting this bit causes the device to power down elements such as memories and register ?es. remark: this bit does not gate the internal module clock or other clocks as clock gating is not allowed inside a module. after setting the powerdown bit, none of the device's registers is accessible, except the one containing the powerdown bit, which is 100% operational. reads from any other register do not hang. writes to any register (except the powerdown bit register) are completed fully or result in an error. the cpu programs the clock module to stop/slow down the clock signals. this assures the clock module is stopped in a controlled way (no glitches/illegal periods). at this point, the register with the powerdown bit is still the only accessible register and the block is fully powered down. 1.1.3 peripheral module wakeup sequence waking up a module is also under cpu control and is the reverse sequence to powerdown: program the clock module so that all related clock sources are set to their normal operational frequencies. reset the powerdown bit in the module. set up the module's con?uration registers if needed. enable the module. 1.1.4 tm3260 powerdown modes the tm3260 cpu has two modes: partial powerdown and full powerdown. partial powerdown mode the tm3260 cpu enters partial powerdown mode by performing a 'store' to a speci? mmio address (the powerdown register). the tm3260s then ?ish any pending transactions and go into a partial powerdown. in partial powerdown mode, cycle counters, timers and interrupt logic in the tm3260s are still active. the tm3260 cpu wakes up from partial powerdown when an interrupt occurs or there is an access to its mmio space. this commonly used by the idle task in an operating system. full powerdown mode the tm3260 also have an externally-initiated full power shutdown mode i.e., no wakeups when an interrupt occurs. entering this mode is requested by asserting an input signal to the tm3260. when this signal is asserted, thetm3260 ?ishes pending transactions and gates-off its core clock.
philips semiconductors pnx15xx series volume 1 of 1 chapter 27: power management 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 27-3 this powerdown state can be initiated by an external host processor by writing to bit tm32_control.tm_pwrdwn_req, see chapter 3 system on chip resources . the tm3260 only exits this mode when this bit is de-asserted. at this point in time the tm3260 clock may be removed by the host. the second method to shutdown the tm3260 clock as well as the mmio clock is to follow the procedure de?ed in chapter 5 the cloc k module section 27 on page 27- 1 . this is solution for standalone systems where pnx15xx series is the master of the system. 1.1.5 sdram controller power consumption of the mmi is lowest when it is halted. there are two different ways to achieve halting the mmi: writing the halt register ?ld of a software programmable mmio register. programming the mmi to go into halt mode automatically after a certain period of inactivity. remark: before halting the mmi, make sure that there are no pending memory transactions. mmio directed halt the halt bit of mmio register ip_2031_ctl can be written with a ??to indicate a request for halting. write a ??to this bit to indicate a request for taking the ddr controller out of halt mode. remark: it is recommended that putting the mmi in mmio direct-halt mode (with mmio registers) before reprogramming the configuration and timing registers in mmi so that the on-going transactions are not effected. when mmio registers ddr_mr and ddr_emr are reprogrammed, a start action has to be performed (after the mmi is unhalted), for the new ddr values to take effect. auto halt the mmi can be programmed such that it goes into halt mode when it has observed a certain period of inactivity. this is accomplished by programming the mmio registers auto_hal_limit and ip_2031_ctl. the mmi will exit the halt mode automatically when a new mtl memory request is presented to one of its input ports. the mtl clock and dcs clock cannot be turned off to operate in this mode. remark: this modes introduces extra latency on memory transactions and it is not a recommended operating mode.
1. introduction several hardware subsystems in the pnx15xx series deal directly with images. such hardware subsystems must follow the same memory representation and interpretation of images in order to successfully pass images between subsystems. software modules also constitute subsystems that can produce or consume images. although most modules are designed with an abstraction layer from the underlying format, some legacy modules may exist that assume a particular pixel representation in memory. in order to run a wide variety of software modules the pnx15xx series uses the following pixel format strategy: a limited number of native pixel formats are supported by all image subsystems, as appropriate. the memory based scaler supports conversion from arbitrary pixel formats to any native format during the anti-?cker ?tering operation. (this operation is usually required on graphics images anyway, so no extra passes are introduced.) hardware subsystems support all native pixel formats in both little-endian and big-endian system operation. software always sees the same component layout for a native pixel format unit, whether it is running in little-endian or big-endian mode?i.e., for a given native format, rgb (or yuv) and alpha are always in the same place. software dealing with multiple units at a time in single instruction multiple data (simd) style must be aware of system endian mode. the native formats of the pnx15xx series include the most common indexed, packed rgb, packed yuv and planar yuv formats used by microsoft ? directx and apple ? quicktime, with 100% bit layout compatibility in both little and big- endian modes. chapter 28: pixel formats pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-2 2. summary of native pixel formats t ab le 1 and figure 1 summarize the native pixel formats and image hardware subsystems that support them. the layout shown in figure 1 is the way that a unit ends up in a cpu register given a unit size (8, 16 or 32-bit) load operation, regardless of the pnx15xx series endian mode of operation. table 1: native pixel format summary name note vip out mpg out mbs in mbs out 2d draw eng (2) qvcp in 1 bpp indexed clut entry = 24-bit color + 8-bit alpha x x 2 bpp indexed xx 4 bpp indexed xx 8 bpp indexed xxx rgba 4444 16-bit unit, containing 1 pixel with alpha (1) x x x x rgba 4534 (1) x x x x rgb 565 16-bit unit, containing 1 pixel, no alpha (1) x x x x rgba 8888 32-bit unit, containing 1 pixel with alpha (1) x x x x packed yuva 4:4:4 32-bit unit containing 1 pixel with alpha x x x x x packed yuv 4:2:2 (uyvy) 16-bit unit, 2 successive units contain 2 horizontally adjacent pixels, no alpha xxx x packed yuv 4:2:2 (yuy2, 2vuy) x x x x planar yuv 4:2:2 3 arrays, 1 for each component x x x semi-planar yuv 4:2:2 2 arrays, 1 with all ys, 1 with u and vs x x x x planar yuv 4:2:0 3 arrays, 1 for each component x x semi-planar yuv 4:2:0 2 arrays, 1 with all ys, 1 with u and vs x x x x semi-planar 10-bit yuv 4:2:2 2 arrays, 1 with all ys, 1 with u and vs 3ys are packed in 4 bytes and 3 sets of uv pixels are packed in 8 bytes x semi-planar 10-bit yuv 4:2:0 2 arrays, 1 with all ys, 1 with u and vs 3ys are packed in 4 bytes and 3 sets of uv pixels are packed in 8 bytes x packed 10-bit yuv 4:2:2(uyvy) 6ys and 3uvs are packed in 16 bytes. x (1) the vip is capable of producing rgb formats, but not when performing horizontal scaling. (2) shown are the 2d drawing engine frame buffer formats where drawing, rasterops and alpha-blending of surfaces can be accelerated. the 2d drawing engine host port also supports 1 bpp monochrome font/pattern data, and 4 and 8-bit alpha only data for host initiated anti-aliased drawings.
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-3 3. native pixel format representation 3.1 indexed formats the indexed formats support a 1, 2, 4 or 8-bit pixel format. for each of the respective 2, 4, 16 or 256 code values, a full look-up for a 24-bit color and 8-bit alpha is performed, using a subsystem-speci?, programmable color look-up table. figure 2 shows the ?oftware view?of the four indexed formats. packing of pixels within the byte always uses the rst, left-most pixel in most signi?ant bit(s) packing convention. pixel groups from left to right have increasing memory byte addresses. (for planar yuv 4:2:0 formats, refer to figure 9 and figure 10 .) figure 1: native pixel format unit layout 1 bpp index i1 0 7 i2 i3 i4 i5 i6 i7 i8 2 bpp index i1 0 7 i2 i3 i4 4 bpp index i1 0 7 i2 8 bpp index i 0 7 0 7 8 15 rgba 4444 0 7 15 rgba 4534 alpha r g b alpha r g b 0 5 15 rgb 565 rgb 4 10 11 12 11 12 11 643 43 0 7 8 15 rgba 8888 alpha g b 16 23 24 31 r g r alpha 0 7 8 15 yuva 444 alpha g u 16 23 24 31 r y v alpha 0 7 uyvy u 8 15 y1 16 23 v 24 31 y2 0 7 yuy2 or y1 8 15 u 16 23 y2 24 31 v 1st unit 2nd unit 2vuy 1st unit 2nd unit
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-4 indexed formats are accepted by the qvcp and mbs. the 2d drawing engine supports 8 bpp indexed as a frame buffer format, but supports no other indexed variants. 3.2 16-bit pixel-packed formats the 16-bit native formats are rgba 4444, rgba 4534 and rgb 565. figure 3 shows the ?oftware view?of these formats. the cpu register layout is always the same when performing 16-bit load/store instructions, regardless of system endian mode. adjacent pixels have left-to-right increasing memory addresses. 16-bit formats are accepted and produced by the qvcp, vip, mbs and the 2d drawing engine. 3.3 32-bit pixel-packed formats the 32-bit formats include rgba 8888 and yuva 4:4:4 with an 8-bit per pixel alpha. figure 4 shows the ?oftware view,?resulting from a 32-bit load into a cpu register. this view is independent of system endian mode. left-to-right pixels have increasing memory addresses. figure 2: indexed formats 1 bpp inde x i1 0 7 i2 i3 i4 i5 i6 i7 i8 2 bpp inde x i1 0 7 i2 i3 i4 4 bpp inde x i1 0 7 i2 8 bpp inde x i 0 7 left-most pixel (group) next pixel (group) right-most pixel (group) . . . . . . memory address a memory address a+1 memory address a+k 1 byte figure 3: 16-bit pixel-packed formats 0 7 8 15 rgba 444 4 alpha r g b 0 5 15 rgb 565 rgb 4 10 11 12 11 43 memory address a memory address a+2 left-most pixel next pixel 16 bit 0 7 15 rgba 453 4 alpha r g b 12 11 6 4 3
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-5 32-bit formats are accepted and produced by all units except the mpeg-2 decoder. 3.4 packed yuv 4:2:2 formats packed yuv 4:2:2 formats store two horizontally adjacent pixels into two 16-bit units. each pixel has an individual luminance (y1 for the left of the pair, y2 for the right of the pair). there is a single u and v value associated with the pair. the u and v values are taken from the same spatial position as the y1 sample ( figure 7 ). there are two variants of packed yuv 4:2:2: the microsoft ?yvy?format and the microsoft ?uy2?format. the big-endian view of the yuy2 format is identical to the power macintosh ?vuy?format. figure 5 and figure 6 show the software view of uyvy and yuy2/2vuy. two successive 16-bit units contain a pair of pixels. this view is independent of system endian mode. figure 4: 32-bit/pixel packed formats 0 7 8 15 rgba 888 8 alpha g b 16 23 24 31 r g r alpha 0 7 8 15 yuva 444 alpha g u 16 23 24 31 r y v alpha 1 byte left-most pixel next pixel right-most pixel . . . . . . memory address a memory address a+4 memory address a+4k 32-bit word figure 5: uyvy packed yuv 4:2:2 format 1 byte left-most pixel pair, 1st unit left-most pixel pair, 2nd unit right-most pixel pair, 2nd un it . . . . . . memory address a memory address a+2 memory address a+4k+2 16-bit word 0 7 uyvy u 8 15 y1 1 6 23 v 24 31 y2 1st unit 2nd unit
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-6 3.5 planar yuv 4:2:0 and yuv 4:2:2 formats the spatial sampling structure of planar yuv 4:2:0 data is shown in figure 8 . the planar yuv 4:2:2 data has the spatial sampling structure as shown in figure 7 . 3.5.1 planar variants there are two variants of planar yuv 4:2:0 and yuv 4:2:2 formats. figure 6: yuy2/2vuy packed yuv 4:2:2 format 1 byte left-most pixel pair, 1st unit left-most pixel pair, 2nd unit right-most pixel pair, 2nd unit . . . . . . memory address a memory address a+2 memory address a+4k+2 16-bit word 0 7 yuy2/2vuy y1 8 15 u 1 6 23 y2 24 31 v 1st unit 2nd unit figure 7: spatial sampling structure of packed and planar yuv 4:2:2 data figure 8: spatial sampling structure of yuv 4:2:0 data chrominance samples luminance samples pair chrominance samples luminance samples
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-7 planar or 3-plane format an image is described by 3 pointer values (py, pu, pv). each pointer points to a 2d array of y, u and v values as shown in figure 9 . semi-planar or 2-plane format an image is described by 2 pointer values (py, puv). the y pointer points to a 2d array of y values. the puv pointer points to a 2d array of uv pair values. note that the u value of a uv pair always has the lower byte address. see figure 10 . figure 9: planar yuv 4:2:0 and 4:2:2 formats py y1 y2 y3 . . . . y2k y1 y2 y3 . . . . y2k y linepitch 1st line 2nd line . . . . . . . . y1 y2 y3 . . . . y2k last line 1 byte w pixels h lines pu u1 u2 u3 . . . . uk u1 u2 u3 . . . . uk u linepitch . . . . . . . . u1 u2 u3 . . . . uk 1 byte k = w/2 times n = h/2 times (4:2:0) pv v1 v2 v3 . . . . vk v1 v2 v3 . . . . vk v linepitch . . . . . . . . v1 v2 v3 . . . . vk 1 byte k = w/2 times n = h/2times (4:2:0) a a+1 a+2 (a) a+2k-1 n = h times (4:2:2) n = h times (4:2:2) (b) (c) b b+1 b+2 c c+1 c+2
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-8 the mbs supports all planar formats on input and output. the vip can produce the planar and semi-planar yuv 4:2:2 planar formats. the semi-planar yuv 4:2:0 format is the only format produced by the mpeg video decoder hardware. figure 10: semi-planar yuv 4:2:0 and yuv 4:2:2 formats py y1 y2 y3 . . . . y2k y1 y2 y3 . . . . y2k y linepitch 1st line 2nd line . . . . . . . . y1 y2 y3 . . . . y2k last line . . . . 1 byte w bytes h lines a a+1 a+2 (a) a+2k-1 puv u1 v1 u2 . . . . vk u1 v1 u2 . . . . vk uv linepitch . . . . . . . . u1 v1 u2 . . . . vk 1 byte w bytes n = h/2 times (4:2:0 ) b b+1 b+2 b+2k-1 (b) n = h times (4:2:2)
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-9 3.5.2 semi-planar 10-bit yuv 4:2:2 and 4:2:0 formats the semi-planar 10-bit yuv 4:2:2 and 4:2:0 formats, shown in figure 11 , are generated by an external device and stored in the pnx15xx series memory through the tunnel interface. qvcp supports the semi-planar 10-bit yuv 4:2:2 and 4:2:0 formats. figure 11: semi-planar 10-bit yuv 4:2:0 and yuv 4:2:2 formats 0 9 10 19 10-bit ys alpha g y1 20 31 y2 10-bit uv s g y3 0 9 10 alpha g u1 31 v1 g u2 address a0 9 alpha g v2 u3 g v3 19 20 19 20 10 0 9 10 19 alpha g y4 20 31 y5 g y6 address a0+4 address b0 31 address b0 + 4 py y3-y1 y6-y4 y9-y7 . . . . y2k - y2k-2 y linepitch 1st line 2nd line . . . . . . . . last line . . . . 4 bytes w(4/3) bytes h lines a a+4 a+8 (a) a+(2k-1)(4/3) puv u2,v1,u1 . . . . uv linepitch 4 bytes w(4/3) bytes n = h/2 times (4:2:0) b b+8 b+(k-1)(8/3) (b) n = h times (4:2:2) y3-y1 y6-y4 y9-y7 . . . . y2k - y2k-2 y3-y1 y6-y4 y9-y7 . . . . y2k - y2k-2 u5,v4,u4 uk-1,vk-2,uk-2 u2,v1,u1 v3,u3,v2 . . . . u5,v4,u4 u2,v1,u1 v3,u3,v2 . . . . u5,v4,u4 . . . . . . . . register view after 32-bit load (applicable to both endianness) note: each word(4byte) is swapped for big-endian and stored in memory vk,uk,vk-1 v3,u3,v2 uk-1,vk-2,uk-2 vk,uk,vk-1 uk-1,vk-2,uk-2 vk,uk,vk-1
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-10 3.5.3 packed 10-bit yuv 4:2:2 format the packed 10-bit yuv 4:2:2 format is generated by an external device and stored in the pnx15xx series memory through the tunnel interface. qvcp supports the packed 10 bit yuv 4:2:2 format, as shown in figure 12 . 4. universal converter the mbs input stage contains a universal pixel format converter that can convert any packed 16 or 32-bit pixel rgb format to an 8-bit alpha, r, g and b value for internal processing. this conversion can be done in combination with any mbs operation, particularly anti-?cker ?tering. the conversion is done by specifying the following: the width (16 or 32 bits) of a unit (this designates endian mode handling) the position (bit 31..0) within the unit for each of the alpha, r,g and b ?lds the width (1..8 bit) of each of the alpha, r,g and b ?lds figure 12: packed 10-bit yuv 4:2:2 format 0 9 10 19 10-bit y,u,v alpha g u1 20 31 y1 g v1 0 9 10 alpha g v2 31 y4 g u3 address a0 9 alpha g y5 v3 g y6 19 20 19 20 10 0 9 10 19 alpha g y2 20 31 u2 g y3 address a0+4 address a0 + 8 31 address a0 + 12 py u1-v1 y2-y3 v2-u3 . . . . y linepitch 1st line 2nd line . . . . . . . . last line . . . . 4 bytes 2w(4/3) bytes h lines a a+4 a+8 (a) u1-v1 y2-y3 v2-u3 . . . . u1-v1 y2-y3 v2-u3 . . . . register view after 32-bit load (applicable to both endianness) note: each word(4-byte) is swapped for big-endian and stored in memory
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-11 5. alpha value and pixel transparency many of the native pixel formats include a per-pixel alpha value. this alpha value is an inverse measure of the ?ransparency?of a pixel. the qvcp and 2d drawing engine are the only subsystems that interpret per-pixel alpha values when compositing surfaces. the native pixel format convention of a per-pixel alpha is shown in t ab le 2 . the qvcp input stage allows full alpha value table look-up using a 256 entry, 8-bit wide table. this can be used to translate a non-native format alpha convention to the native convention. 6. rgb and yuv values 8-bit data for 8-bit data, the full range of values is allowed i.e., [0~255]. as an option, the data range could be clipped in the mbs or vip according to the itu-k bt. 601-4 speci?ation. y range [16~235] u range [16~240] v range [16~240] or r range [16~235] g range [16~235] b range [16~235] 10-bit data for 10-bit data, the full range of values is allowed i.e., [0~1023]. the blank level is programmable through the register. 7. image storage format with the exception of the planar formats, described in section 3.5 , the layout of an image in memory is determined by the following elements: table 2: alpha code value and pixel transparency alpha code transparency value 0 fully transparent 0/256 1 almost fully transparent 1/256 ... 254 almost fully opaque 254/256 255 fully opaque 256/256
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-12 pixel format, which implies the unit size(s) origin pointer?he (byte) address of the ?st unit of the image line pitch?he address difference between a pixel on a line and a pixel directly below it width w, in number of pixels height h, in number of lines note that for indexed formats, each unit contains one or more pixels. for the packed formats, a unit is a pixel, with the exception of packed yuv 4:2:2 where two units are needed to describe a pixel pair. figure 13 shows how images are stored in memory 8. system endian mode the pnx15xx series is designed to run either little-endian or big-endian software. the entire system always operates in a single endian mode?.e. the cpu and all hardware subsystems run either little or big-endian. this is determined by a global endian mode ?g. the endian mode determines how a multi-byte value is stored to/loaded from memory byte addresses. for the native pixel formats, section 3. always shows two elements in the ?ures: the layout of a ?nit? which is always 8, 16 or 32 bits, and the mapping of adjacent units to memory byte addresses. these two elements are always maintained, independent of system endian mode. what this implies is that each hardware subsystem needs to map a unit to memory byte addresses in an endian mode-dependent manner. the rules are as follows: storing a 16-bit unit to address ??results in modifying memory bytes ??and ?+1 storing a 32-bit unit to memory address ? results in modifying memory bytes ? to ?+3 figure 13: image storage format origin unit1 unit2 unit3 . . . . unitk . . . . linepitch 1st line 2nd line . . . . . . . . . . . . last line 1unit w pixels h lines a a+s a+2s a+(k-1)s unit1 unit2 unit3 unitk unit1 unit2 unit3 unitk (a)
philips semiconductors pnx15xx series volume 1 of 1 chapter 28: pixel formats 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 28-13 in little-endian mode, the least signi?ant bits of a unit go to the lowest byte address in big-endian mode, the most signi?ant bits of a unit go to the lowest byte address going from left to right, adjacent units go to increasing memory addresses
1. introduction two addressing conventions exist in the computer industry: little-endian and big-endian. in the little-endian convention, a multi-byte number is stored in memory with the least signi?ant byte at the lowest memory address, and subsequent bytes at increasing addresses. in the big-endian convention, the most signi?ant byte is stored at the lowest memory address, and subsequent bytes are stored at increasing addresses. the pnx15xx series supports both big-endian mode and little-endian mode, allowing it to run either little-endian or big-endian software, as required by the particular application. this chapter explains the concepts and programmers view of data structures required for module control and module dma. the chapter also contains a section that shows how hardware modules, buses and bridges implement the programmers view. 1.1 features the pnx15xx series supports big-endian and little-endian operation. the system as a whole (all cpus and all on-chip dma modules) must operate in the same endian mode. when used with an external cpu, the pnx15xx series must operate in the same endian mode as the external cpu. if the endian modes between the external cpu and the pnx15xx series are different, then the external cpu must be aware of this difference and appropriately handle all data swapping. the endian-mode choice is made at boot time. it can be changed by software, but this requires a partial system reset. chapter 29: endian mode pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-2 2. functional description 2.1 endian mode system block diagram figure 1 shows a system block diagram with two example of dma modules. each dma module deals with a 16-bit unit size. module 1 transfers data via a 32-bit dtl bus with dtl data ordering rules, while module 2 transfers data via a 32-bit dtl bus with address-invariance rules. for the following, assume that both modules are input
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-3 modules that move data to system memory via a dtl-dma interface. for dma output modules that read data from memory, the operation is similar but in the opposite direction. figure 1: system block diagram: endian-related blocks 64 dma buffering dtl (64-bit) packer lego packing 64 dma buffering dtl (64-bit) packer lego packing 64 packing endian swap 32 imodule 2 packing 32 module 1 endian swap cmd_data_size msb lsb unit view byte 1 byte 0 byte view 32 standardized bus mtl mmi hub
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-4 3. endian mode theory there are two basic laws of endian mode: one imposed by cpu history, and one by convention. both must be met by any system architecture that implements dual- endian operation capability. in addition, there are some implementation choices for a system architecture. section 6. explains the choices that were made for the pnx15xx series on-chip buses. these choices are somewhat arbitrary, but they must be followed to ensure future compatibility. 3.1 law 1: the ?pu rule this section is intended to explain cpu endian modes in detail. for those familiar with cpus and endian modes, it is optional reading. the following summarizes how cpus and byte-addressable memory operate: when storing an ? byte size item from a cpu register to memory at address ?, the bytes modi?d are always the bytes with byte address ??.?+n-1. in little-endian mode, the byte at address ??receives the least signi?ant bits of the multi-byte item. in big-endian mode, the byte at address ??receives the most signi?ant bits. consider the following example a (hypothetical) c struct: struct { uint8c;//"command" byte uint8f;//"flags" byte uint16l;//"length" 16 bit value uint32a;//"address" 32 bit value } dma_descriptor; remark: this is based on an example in the apple ? publication, ?esigning pci cards and drivers for power macintosh computers,?appendix a. a compiler would assign byte offsets as follows: c:0, f:1, l:2, a:4. this assignment is independent of system endian mode. figure 2 and figure 3 show the two layout views. figure 2: big-endian layout of dma_descriptor c f l a 01 2 4 word 1 word 2
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-5 the tm3260 cpu on the pnx15xx series both support 8, 16 and 32-bit data types and a memory system that is byte addressable. the cpu support a big-endian and little-endian mode of operation. the effect of a cpu store instruction on memory is de?ed in t ab le 1 . as an example, a 16-bit store operation always stores the 16-bit quantity contained in the 16 lsbits of the cpu register. and the memory locations affected are ??and ?+1.?but which byte goes where is dependent upon endian mode. the effect of a cpu load instruction on a register is de?ed for unsigned and signed loads in t ab le 2 and t ab le 3 . note that a load always sets all bits of the cpu register. in the case of an unsigned load, higher order bits are ?led with zeroes. in the case of a signed load, higher order bits are ?led with the sign bit of the data item loaded. figure 3: little-endian layout of dma_descriptor table 1: memory result of a store to address ??instruction endian mode r13 content data size result of store size (r13, address a) little 0x04050607 8 bits m[a] = 0x07 little 0x04050607 16 bits m[a] = 0x07; m[a+1] = 0x06 little 0x04050607 32 bits m[a] = 0x07; m[a+1] = 0x06; m[a+2] = 0x05; m[a+3] = 0x04 big 0x04050607 8 bits m[a] = 0x07 big 0x04050607 16 bits m[a] = 0x06; m[a+1] = 0x07 big 0x04050607 32 bits m[a] = 0x04; m[a+1] = 0x05; m[a+2] = 0x06; m[a+3] = 0x07 c f l a 0 1 2 4 word 2 word 1 table 2: register result of an (unsigned) load instruction memory content endian mode data size register value result of load size (address a) m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd little 8 bits 0x000000aa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd little 16 bits 0x0000bbaa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd little 32 bits 0xddccbbaa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd big 8 bits 0x000000aa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd big 16 bits 0x0000aabb m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd big 32 bits 0xaabbccdd
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-6 an interesting example is the small c program below that determines whether the program runs on a big-endian or little-endian mode machine. int w = 0x04050607; char *a = (char *) &w; if (*a == 0x04) printf("big-endian"); else printf("little-endian"); 3.2 law 2: the ?ma convention rule the dma convention rule says that ?hen a stream of items enters the system, items should be placed in memory such that an item that arrived later has a higher address value. on output, a similar convention holds?tems sent ?st are those with the lowest addresses. a variant of this rule relates to the storage of images. pixels from left to right have increasing addresses. lines from top to bottom have increasing addresses. this is a convention that keeps programmers sane. it may also be seen as arbitrary, but obviously the best choice between two alternatives. a more precise version of this rule is: if item ??of a dma item stream is placed at address ?,?item ??of a dma stream should be placed at byte address ?+i*s, where ??is the item size in bytes. for an example of this rule, refer to section 5. table 3: register result of a (signed) load instruction memory content endian mode data size register value result of load size (address a) m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd little 8 bits 0xffffffaa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd little 16 bits 0xffffbbaa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd little 32 bits 0xddccbbaa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd big 8 bits 0xffffffaa m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd big 16 bits 0xffffaabb m[a] = 0xaa; m[a+1] = 0xbb; m[a+2] = 0xcc; m[a+3] = 0xdd big 32 bits 0xaabbccdd figure 4: memory content created by the c program int w = 0x04050607; char *a = (char *)&w; 04 05 06 07 big-endian mode memory content little-endian mode memory content a+0 04 05 06 07 a+3 a+1 a+2 a+3 a+2 a+1 a+0 0 31 04 05 06 07 cpu register content
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-7 4. pnx15xx series endian mode architecture details the programmers view of the pnx15xx series endian architecture is as follows: the cpu and the modules on the pnx15xx series store and retrieve audio samples, image pixels and data observing both the cpu rule and dma rule. the system as a whole runs in either little-endian or big-endian mode. the mode is determined by the ?ig_endian?bit in the sys_endianmode register, see chapter 3 system on chip resources section 3.3 on page 3- 8 , which is ?xported?to other modules. the value of this bit is set during system initialization. 4.1 global endian mode the cpu and all the modules always operate in a single endian mode. this endian mode is determined by the big_endian bit in the sys_endianmode register of the pnx15xx series global register module. the value of this bit is set during system boot and normally not changed afterward. remark: the tm32 cpu core endian mode is determined by a bit in its pcsw. this is historically set by the ?rt0.s software module on the tm32 cpu core, which initializes the pcsw. the pnx15xx series version of this software module is responsible for reading the sys_endianmode.big_endian bit value and establishing the same tm32 cpu core endian mode as the rest of the system. 4.2 module control all the modules have control and status registers, accessed by cpu programmed i/ o. in the pnx15xx series, all programmed i/o happens through memory mapped i/o registers. a separate device control and status bus (dcs bus) is used for all mmio programming. a cpu can access device control and status registers by using the correct mmio address for a module register. in the pnx15xx series, all module registers are 32 bits wide and may only be accessed through 32-bit load/store operations. a control/status register load/store always copies the 32 bits verbatim between a cpu register and the module register. the modules left-most msb (bit 31) ends up in the cpus left-most msb (bit 31), and the modules right-most lsb (bit 0) ends up in the right-most cpu register bit. this happens regardless of system endian mode settings. mmio load and store instructions always see the same bit layout of module mmio registers, regardless of endian mode. the ?ld and bit layout is precisely as speci?d in the module register table with bit 31 designating the msb and bit 0 the lsb. remark: the packing and ordering of packed bit structure fields in c compilers are not precisely defined. typically, big-endian c compilers pack fields from left (msb) to right (lsb). little-endian c compilers pack from right to left. because of this and also because of inherent inefficient code when accessing structure fields, it is not recommended to use c structure declarations to access mmio register fields.
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-8 4.3 module dma every dma capable module in pnx15xx series observes the system big-endian signal, and therefore the global sys_endianmode.big_endian value, to determine how to write each data item or unit to memory. an example of a unit would be: 16-bit audio sample 32-bit audio sample 32-bit unit containing a rgba 8888 true color pixel with alpha value. the module performs byte swapping within units as needed, and packs units as needed for transmission across on-chip buses. byte swapping is done in such a fashion that 8, 16 and 32-bit units always end up in memory bytes in the form prescribed by the cpu rule. successive item packing are placed in incrementing addresses, as designated by the dma rule. 4.4 simd programming issues the module dma hardware architecture ensures that software dealing with loads and stores of unit size data can be written in a way that is oblivious to the endian mode. with the current tm32 cpu core, this is not possible for software that performs single instruction multiple data (simd) style programming using multimedia operations. consider the case of a fir ?ter, operating on 16-bit sample units, but using 2-at-a-time load/store/multiply operations. which of the two 16-bit halfwords is the earlier sample? for big-endian mode, the msb halfword contains the earlier sample. for little-endian mode, the lsb halfword contains the earlier sample. the current tm32 cpu core on pnx15xx series requires that simd software be written aware of endian mode. 4.5 optional endian mode override some pnx15xx series dma modules have bits in a control register that allow override of the global endian mode. refer to each module for details. this method is used only in modules that deal with dma of data of a single, ?ed size (in a given mode). such modules implement a ?ld that allows selection of the following modes: normal mode (reset default), obey global pnx15xx series endian mode explicit little-endian, unswapped swap over 16 bits swap over 32 bits
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-9 5. example: audio in?rogrammers view the pnx15xx series audio in module receives mono or stereo, 8 or 16-bit/sample audio data and ?ls memory with an 8 or 16-bit data structure. the data structure is put in memory according to both endian mode laws. a programmers view of the audio in function is sketched in figure 5 . the programmer sees the address of each item (according to the dma rule), and expects that 16-bit values are correctly stored in memory according to the cpu law. the dma logic of the audio in module therefore needs to write data in memory (byte) locations precisely, per t ab le 4 . note the programmer also sees the control and status registers of the audio in module per figure 6 . these registers are always seen with the same bit-layout in the cpu register, regardless of endian mode. figure 5: audio in memory data structure (programmers view) addr left n addr+1 left n+1 addr+2 left n+2 addr+3 left n+3 addr+4 left n+4 addr+5 left n+5 addr+6 left n+6 addr+7 left n+7 8-bit mono addr left n addr+1 right n addr+2 left n+1 addr+3 right n+1 addr+4 left n+2 addr+5 right n+2 addr+6 left n+3 addr+7 right n+3 8-bit stereo 16-bit mono left n addr left n+1 addr+2 left n+2 addr+4 left n+3 addr+6 16-bit stereo left n addr right n addr+2 left n+1 addr+4 right n+1 addr+6 table 4: precise mapping audio in sample time and bits to memory bytes operating mode m[addr] m[addr+1] m[addr+2] m[addr+3] 8-bit mono?ittle-endian or big-endian left n [7:0] left n+1 [7:0] left n+2 [7:0] left n+3 [7:0] 8-bit stereo?ittle-endian or big-endian left n [7:0] right n [7:0] left n+1 [7:0] right n+1 [7:0] 16-bit mono?ittle-endian left n [7:0] left n [15:8] left n+1 [7:0] left n+1 [15:8] 16-bit mono?ig-endian left n [15:8] left n [7:0] left n+1 [15:8] left n+1 [7:0] 16-bit stereo?ittle-endian left n [7:0] left n [15:8] right n [7:0] right n [15:8] 16-bit stereo?ig-endian left n [15:8] left n [7:0] right n [15:8] right n [7:0]
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-10 6. implementation details the pnx15xx series system has two different bus structures: device control and status network, or dcs network; and pipelined memory access network, or pman network, or mtl bus. 6.1 pman network endian block diagram the system endian mode of operation is designated to each component by the system big-endian signal - ??for big-endian mode, ??for little-endian mode. referring to figure 1 , note that both modules are identical. they perform all dma data transfers across a standard 32-bit ?tl interface. module 1 uses the data ordering rules according to t ab le 5 while module 2 uses the address invariance rules according to t ab le 6 . the pman interface to module 1 therefore has to convert the data format to address invariant format (this is done in the "endian swap" portion of the pman structure) while module 2 does not require any such conversion (the module is already in the address invariant format). the rest of the pman and memory interface structure is address invariant. the pman endian swap unit (as shown for module 1) or the module endian swap unit (as shown in module 2), must deal with unit endian swapping and unit packing . swapping is de?ed as ?ositioning each byte of a unit correctly with respect to the memory byte address that it is supposed to go to. swapping is what implements the cpu rule. packing is de?ed as ?he action that places consecutive units simultaneously on a wider bus in order to implement the dma rule. the dma module need not be aware of the details of either the dtl, or the mtl bus. it just swaps and packs, based on its knowledge of unit size and system endian mode, and creates the valid dtl interface data. figure 6: audio in control/status mmio registers ai_status (r/w) ai_ctl (r/w) buf1_active overrun hbe (highway bandwidth error) buf2_full buf1_full reserved reset cap_enable cap_mode sign_convert diag_mode ovr_inten hbe_inten buf2_inten buf1_inten ack_ovr ack_hbe ack2 ack1 31 27 23 19 15 11 7 3 0 31 27 23 19 15 11 7 3 0
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-11 two standard solutions are provided to interface the dtl to the pman mtl network buses: the ?man buffer?connects the 32-bit dtl interface to the mtl-bus. the ?acker lego and ?ma buffering map the 32-bit dtl interface to the 64-bit mtl memory bus. note that the connection from the 32-bit dtl interface to the mtl bus uses swapping only if the 32-bit dtl interface is not address invariant. the following subsections show how unit data of different lengths travels across the three key interfaces: the 32-bit dtl interface, the dcs network and the mtl memory bus. 6.2 dma across a dtl interface modules that interface to the dtl bus can deal with data on the bus in two ways: data can be put on the bus in their natural form (without ?pping them for endian mode but indicating the size of the data with cmd_data_size ). in this case, the module is not aware of the sys_endian bit in the system. the module follows dtl data ordering rules. modules can put the data on the bus in the address invariant mode (note: this is also the 8-bit mode). in this mode, the module uses the sys_endian bit to ?p the data appropriately depending on the size of the data and the system endian mode. 6.2.1 dtl data ordering rules data is transferred across the dtl interface by the following rules: the value of cmd_data_size indicates the width of the data item(s) as 8 * 2 cmd_data_size bits. for example, with 8-bit data, cmd_data_size is set to 0x0, for 16-bit data, cmd_data_size is 0x1, etc. in all cases, the data item (e.g. byte) that corresponds to the lowest address is transferred on the low order data bits of the dtl rd_data or wr_data modules dealing with 8, 16 or 32-bit units must place bytes on the dtl interface given in t ab le 7 . the endian swap units then convert the data into true address invariant views based on the cmd_data_size . table 5: dtl interface rules module item unit size system endian mode dtl_d[31:24] dtl_d[23:16] dtl_d[15:8] dtl_d[7:0] 8 bits either item #4 with address a+3 item #3 with address a+2 item #2 with address a+1 item #1 with address a 16 bits either item #2 with address a+2 item #1 with address a bits 15..8 bits 7..0 bits 15..8 bits 7..0 32 bits either item with address a bits 31..24 bits 23..16 bits 15..8 bits 7..0
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-12 6.2.2 address invariant data ordering rules the address invariance rule of the dtl interface is given in t ab le 6 . a given byte lane implies the address, regardless of endian mode of the system. modules dealing with 8, 16 or 32-bit units must place bytes on the dtl interface given in t ab le 7 . 6.3 data transfers across the dcs network the dcs network is said to be ?ndian neutral? although this bus is intended to transfer mainly 32-bits of control and status data, it can carry smaller units of data (8-bit, 16-bit for e.g., cpu accesses to pci devices). accesses on this bus are mainly mmio accesses. the only memory accesses allowed are for booting purposes via the dcs gate module. this is only accessed by the boot module. the dcs network is not designed for dma burst transfers. modules that transfer smaller data items (8- or 16-bit) must observe the packing rules in t ab le 8 . table 6: 32 bit dtl interface byte address dtl-d[31:24] dtl-d[23:16] dtl-d[15:8] dtl-d[7:0] 4n+3 4n+2 4n+1 4n+0 table 7: dtl interface rules module item unit size system endian mode dtl_d[31:24] dtl_d[23:16] dtl_d[15:8] dtl_d[7:0] 8 bits either item #4 with address a+3 item #3 with address a+2 item #2 with address a+1 item #1 with address a 16 bits big item #2 with address a+2 item #1 with address a bits 7..0 bits 15..8 bits 7..0 bits 15..8 16 bits little item #2 with address a+2 item #1 with address a bits 15..8 bits 7..0 bits 15..8 bits 7..0 32 bits big item with address a bits 7..0 bits 15..8 bits 23..16 bits 31..24 32 bits little item with address a bits 31..24 bits 23..16 bits 15..8 bits 7..0 table 8: dcs network data transfer rules (32 bits at-a-time transfer) module item unit size system endian mode dcs_d[31:24] dcs_d[23:16] dcs_d[15:8] dcs_d[7:0] 8 bits big item #1 with address a item #2 with address a+1 item #3 with address a+2 item #4 with address a+3 8 bits little item #4 with address a+3 item #3 with address a+2 item #2 with address a+1 item #1 with address a
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-13 6.4 dma across the mtl bus the 64-bit mtl bus associates byte-addresses with byte lanes in a ?ed manner, independent of system endian mode, according to t ab le 9 . modules that directly place data in or retrieve data from memory are dma modules. high bandwidth modules, or modules that require low latency access to memory, perform dma over the mtl bus. dma modules use large (64-byte or larger) block transfers using the 8-byte lanes of the mtl bus within the hub. modules that deal with 8, 16 or 32-bit item data sizes and connect directly to the mtl bus must follow the rules in t ab le 10 . note in particular the bit numbers of the 16 and 32-bit data items in big-endian modes. modules that use the dtl interface can rely on the standard packer and dma endian swap units to accomplish the mtl bus rules. 16 bits big item #1 with address a bit15.....................................bit0 item #2 with address a+2 bit15.....................................bit0 16 bits little item #2 with address a+2 bit15.....................................bit0 item #1 with address a bit15.....................................bit0 32 bits either item (address a) bit31............................................................................................ .bit0 table 8: dcs network data transfer rules (32 bits at-a-time transfer) ?ontinued module item unit size system endian mode dcs_d[31:24] dcs_d[23:16] dcs_d[15:8] dcs_d[7:0] table 9: mtl memory bus byte address data[63:56] data[55:48] data[47:40] data[39:32] data[31:24] data[23:16] data[15:8] data[7:0] 8n+7 8n+6 8n+5 8n+4 8n+3 8n+2 8n+1 8n+0 table 10: mtl memory bus item dma rules module item unit size system endian mode data [63:56] data [55:48] data [47:40] data [39:32] data [31:24] data [23:16] data [15:8] data [7:0] 8 bits either item # 8 addr a+7 item #7 addr a+6 item #6 addr a+5 item #5 addr a+4 item #4 addr a+3 item #3 addr a+2 item #2 addr a+1 item #1 addr a 16 bits big item #4 address a+6 b7...b0 b15...b8 item #3 address a+4 b7...b0 b15...b8 item #2 address a+2 b7...b0 b15...b8 item #1 address a b7...b0 b15...b8 16 bits little item #4 address a+6 b15...b8 b7...b0 item #3 address a+4 b15...b8 b...b0 item #2 address a+2 b15...b8 b7...b0 item #1 address a b15...b8 b7...b0 32 bits big item #2 address a+4 b7...b0 b15...b8 b23...b16 b31...b24 item #1 address a b7..b0 b15...b8 b23...b16 b31...b24 32 bits little item #2 address a+4 b31...b24 b23...b16 b15...b8 b7...b0 item #1 address a b31...b24 b23...b16 b15...b8 b7...b0
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-14 6.5 dtl-to-mtl adapters the dtl-to-mtl adaptor translates dtl-bus initiated read and write transactions to mtl memory transactions. the dtl interface can either be an address invariant (see section 6.2.2 on page 29- 12 ) or follow dtl data ordering rules (see section 6.2.1 on page 29- 11 ). for dtl interfaces that are address invariant, the translation is performed in a byte- address invariant way, i.e. the byte address associated with every 8-bit quantity must be equal on each side of the bridge. note that this translation need not be aware of the unit size being transported. the module that was the originator of units has performed swapping and packing such that each byte has been given the correct byte address. for dtl interfaces that follow dtl data ordering rules, the translation takes into account the data unit size on the dtl and the system endian mode, and converts the data into an address invariant view on the mtl interface. the module that was the originator of units need not perform swapping and packing such that each byte has been given the correct byte address (the ip need not be aware of the system endianmode signal). the translation occurs in two steps. when writing data to memory, the ?st step ?ps the 32-bit dtl-bus writes to a 32-bit address invariant view (depending on endian mode and unit data size). the second step performs packing from this 32-bit address-invariant data to the 64-bit mtl memory bus. for modules that read memory data, the two steps occur in the reverse direction. the mtl-bus associates addresses with each byte transferred, depending on the dtl-bus unit data size and the setting of the big-endian signal. this byte address is given in t ab le 8 , where the value ??denotes the integer value on pi-bus a[n:2] address wires. the dtl interface can either follow the address invariance rules (as indicated in t ab le 7 ) or follow dtl data ordering rules (as indicated in t ab le 5 ). 6.6 pci interface the pci interface on the pnx15xx series connects to the off-chip pci-bus, the dcs network and the mtl memory bus. as with any bridge, the pci interface must maintain the byte address of any byte of a transaction on all sides of the bridge. the pci interface bridges the following transactions in the pnx15xx series: pci master read/writes from/to pnx15xx series mmio registers using 32-bit transactions only pci master read/writes from/to pnx15xx series sdram dcs network master initiated read/writes from/to pci targets pci interface internal dma transactions, where the source can be a pci target or dram, and the destination is a pci target or dram.
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-15 the 32-bit pci bus uses byte address conventions identical to the dtl interface and mtl memory bus interface: refer to t ab le 11 . the dcs network uses byte address conventions given in t ab le 8 . the mtl memory bus uses the byte address conventions given in t ab le 9 . with the above byte address conventions on the three sides of the bridge and the byte address invariance rule for bridges, the swap modes can be derived. since the convention on the pci bus closely matches those on the mtl bus. 7. detailed example this section describes all steps involved in how a big-endian mode external cpu (e.g., a power macintosh), paints an rgb-565 pixel format frame buffer in the pnx15xx series sdram and how this is displayed on the qvcp. this example illustrates the following: the power macintosh pci bridge and its address invariance rule based swapper the big-endian pci pixel transfer how data arrives correct in sdram in native rgb565 pixel format how the qvcp takes it and displays it how the tm32 cpu core sees the data the power macintosh was the ?st platform that successfully demonstrated big- endian operations across the pci bus. details of how this works can be found in the apple document ?esigning pci cards and drivers for power macintosh computers. suppose that the big-endian cpu in the power macintosh uses a 32-bit store operation to create two rgb565 pixels. pixel 1, the left-most pixel, has (byte) address ??and pixel 2 has address ?+2.?since these two pixels are transferred in a single 32-bit word, ??is a multiple of 4. the intermediate stages that the data goes through can be found in figure 7 table 11: 32 bit pci interface byte address pci-ad[31:24] pci-ad[23:16] pci-ad[15:8] pci-ad[7:0] 4n+3 4n+2 4n+1 4n+0
philips semiconductors pnx15xx series volume 1 of 1 chapter 29: endian mode 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 29-16 note that the power macintosh architecture contains a pci bridge that maintains byte address invariance. since all stages inside the pnx15xx series maintain byte addresses, the end-to-end result of the complex sequence of actions is a successfully rendered pair of rgb565 pixels. it is recommended to use only external big-endian cpu/pci bridge combinations that implement the power macintosh style byte-invariant address model with the pnx15xx series. some external cpu pci bridges may only contain a static, transaction-size cpu unaware swapper. the use of such external components is not recommended and will require special care in software. figure 7: big-endian external cpu drawing two rgb-565 pixels lsb msb p1.r p1.g p1.b p2.r p2.g p2.b powerpc cpu register content create by software a a+1 a+2 a+3 powerpc cpu data byte address association ad00 ad31 ?ib endian?rgb565 transport across pci bus, as described in a+3 a+2 a+1 a data byte address association ?wap?as performed by power mac pci bridge (for 32-bit cpu store operations) p1.r p1.g p1.g p1.b p2.r p1.g p2.g p2.b p1.r p1.g p1.b p2.r p2.g p2.b big-endian view of resulting sdram content a a+1 a+2 a+3 32 lsbits (or msbits) of 64-bit qvcp read across mtl bus a+3 a+2 a+1 a data byte address association p1.r p1.g p1.g p1.b p2.r p1.g p2.g p2.b qvcp view after unit unpack a+1 a data byte address association p1.r p1.g p1.g p1.b p1.r p1.g p1.b a a+1 qvcp view after big-endian mode swap data byte address association pci multimedia design guide, revision 1.0 ??epresents partial bits from the ??pixel
1. introduction the pnx15xx series device control and status (dcs) network architecture is designed to support the following: separates mmio traf? from dma traf?: the tm3260 core has a high-performance, low-latency path to memory. tm3260 i cache and dcache traf? is separated. provides low latency access to modules: the tm3260 core has a low latency access to different modules of pnx15xx series system. supports timeout generation. 2. functional description the dcs bus is intended for mmio traf? to con?ure the various modules in the system. all modules can be accessed by the boot module, and external pci master or the tm3260 itself. access between the dcs bus and the memory is provided by the dcs-gate. this path is to be used by the boot module only! figure 3 on page 3- 30 in chapter 3 system on chip resources pictures pnx15xx series dcs bus. a generic ?evice transaction level?(dtl) point-to-point initiator-target communication protocol is used on the boundary between a module and the dcs bus. mmio communication through the dtl protocol always consists of a single 32- bit data element. each module on the dcs bus has a unique id. the bus controller provides programmable timeout generation with the following features: captures error and timeout information: initiator id of the currently granted dcs initiator 32-bit address of the currently granted dcs transaction encoded target number for the currently selected dcs device additional information including read or write command information allows interrupt generation for any non-masked timeouts and errors. the dcs network controllers generate selects for all the dcs targets according to the address on the dcs network aperture map. see chapter 3 system on chip resources , section 11. on page 3- 31 for addresses of dcs target apertures. chapter 30: dcs network pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 30: dcs network 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 30-2 in the total aperture range there are holes, a.k.a. ?ull?modules, between the different mmio targets speci?d by noncontiguous offsets. each hole is considered a null target. when an offset of 0xffc within each hole is addressed, the controller will respond with a module id and the size of the region. 2.1 error generation error capture registers inside the network controller will capture the current address and operation that was in progress when an error is reported or when a timeout occurs. once an error has been captured, the capture registers are no longer updated until the interrupt is cleared. errors caused by tm3260 32-bit read operations are not captured , and not reported to the tm3260. therefore, when the currently selected initiator is the tm3260 (as determined by the arbiter), if the operation is a read, and the mask is all ones, any errors are blocked, including timeout errors . in this case, the capture registers are not updated and error signals are not asserted. this is to prevent errors on speculative loads. 2.2 interrupt generation the dcs network controller generate an interrupt for: error acknowledge detected on the dcs network dcs network timeout these interrupts can be enabled, cleared, software set and status seen by accessing registers on top of the dcs network controllers mmio space. 2.3 programmable timeout the timeout block uses a 17-bit counter to count clock cycles of an active transaction. the counter increments when the select signal (sel) is high. the counter synchronously resets to zero when sel is low. when the timeout counter reaches a certain value determined by the control register bc_ctrl, the counter stops incrementing and the abort_all signal is sent to the currently selected target. each timeout limit is a number equal to 2n-1, allowing the timeout detection circuit to be a simple mux which selects one bit from the timeout counter. note that the three least signi?ant bits of the counter are not monitored, because no transaction can complete in less than four clock cycles. when a timeout occurs, the abort signal is asserted to the currently selected target. the timeout condition is also logically ored with the dcs error input to force an error indication back to the target. 2.3.1 arbitration a ?ound robin?arbiter is used to selective grant access to each of the requesting initiators. the arbiter will default grant the last device that was granted. therefore, when no initiator is requesting access, the default grant will be given to the initiator
philips semiconductors pnx15xx series volume 1 of 1 chapter 30: dcs network 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 30-3 that most recently performed a transaction. the initiator with a default grant can access a target one clock cycle faster than an initiator without the default grant. assigning the default grant to the initiator that most recently used the ?us?is expected to yield the highest performance, since one initiator is likely to execute several transactions at once. to achieve the round robin feature with a dynamic default grant, the arbiter uses an internal priority comparator. the comparator selects an initiator to grant by comparing the ?riorities?of each device. the priority value consists of three bits. the most signi?ant bit is high when there is a pending request from that initiator. the second most signi?ant bit is generated by ?ast_grant? which will be high for the most recently granted initiator only if that initiator does not have a pending request , and low for all other initiators. the third bit is a ?niform scheduling?value. this will be set to one for all bit locations higher than the last granted initiator and zero for all lower ones. the priority block will pick the highest value (3-bit) input. in the case of a tie, the lower numbered port will win. 2.4 endian mode all dcs network ports use 32-bit data paths and the data values are viewed as 32-bit quantities. even when an 8 or 16-bit read or write is performed, the transfer is considered to be a portion of a larger 32-bit quantity. the data transfers are never viewed as packed 8 or 16-bit values. 3. register descriptions 3.1 register summary t ab le 1 summarizes the control and status registers visible inside the dcs controller. remark: the bc_int_en register is r/w, however newly written software drivers should consider bc_int_en as read only and should use the bc_int_clr_enable and bc_int_set_enable registers to update the value of bc_int_en. table 1: dcs controller_trimedia con?uration register summary offset symbol description 0x10 3000 bc_ctrl timeout control register 0x10 300c bc_addr error and timeout address register 0x10 3010 bc_stat error and timeout status register 0x10 30d8 bc_int_clr_enable clear bits in bc_int_en 0x10 30dc bc_int_set_enable set bits in bc_int_en 0x10 3fe0 bc_int_status interrupt status register 0x10 3fe4 bc_int_en interrupt enable register 0x10 3fe8 bc_int_clr interrupt clear register 0x10 3fec bc_int_set interrupt software set register 0x10 3ffc bc_mod_id module identi?ation and revision information
philips semiconductors pnx15xx series volume 1 of 1 chapter 30: dcs network 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 30-4 3.2 register tables t ab le 2 shows detailed bit locations for each register. table 2: dcs controller_trimedia con?uration registers (rev 0.32) bit symbol acces s value description offset 0x10 3000 bc_ctrl 31:5 reserved - ignore upon read. write as zeros 4:1 tout_sel[3:0] r/w 0x0 timeout select 0x0 = timeout generated after 7 consecutive wait cycles. 0x1 = timeout generated after 7 consecutive wait cycles. 0x2 = timeout generated after 7 consecutive wait cycles. 0x3 = timeout generated after 15 consecutive wait cycles. 0x4 = timeout generated after 31 consecutive wait cycles. 0x5 = timeout generated after 63 consecutive wait cycles. 0x6 = timeout generated after 127 consecutive wait cycles. 0x7 = timeout generated after 255 consecutive wait cycles. 0x8 = timeout generated after 511 consecutive wait cycles. 0x9 = timeout generated after 1,023 consecutive wait cycles. 0xa = timeout generated after 2,047 consecutive wait cycles. 0xb = timeout generated after 4,095 consecutive wait cycles. 0xc = timeout generated after 8,191 consecutive wait cycles. 0xd = timeout generated after 16,383 consecutive wait cycles. 0xe = timeout generated after 32,767 consecutive wait cycles. 0xf = timeout generated after 65,535 consecutive wait cycles 0 tout_off r/w 0x1 timeout disable 0x0 = timeout enabled. 0x1 = timeout disabled. offset 0x10 300c bc_addr 31:2 err_tout_addr[31:2] r 0x00000 000- full 30 bits of the address which causes an error or timeout. 1:0 reserved - ignore upon read. write as zeroes. offset 0x10 3010 bc_stat 31:29 reserved - ignore upon read. write as zeroes. 28:24 err_tout_gnt[4:0] r 0x0 active initiator causing error or timeout -- initiator id of the current pending transaction will be captured: 1: tm3260 2: boot 4: pci 23:17 reserved ignore upon read. write as zeroes.
philips semiconductors pnx15xx series volume 1 of 1 chapter 30: dcs network 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 30-5 16:10 err_tout_sel[6:0] r 0x00 selected agent during error or timeout 7? 0000000 = pci 7? 0000001 = i 2 c 7? 0000010 = clocks 7? 0000011 = 2dde 7? 0000100 = reset 7? 0000101 = tmdbg 7? 0000110 = system registers 7? 0000111 = mtl arbiter, a.k.a. ip1010 7? 0001000 = ddr controller, a.k.a. ip2031 7? 0001001 = fgpi 7? 0001010 = fgpo 7? 0001011 = lan100 7? 0001100 = lcd 7? 0001101 = vld 7? 0001110 = tm3260 7? 0001111 = gpio 7? 0010000 = vip 7? 0010001 = spdo 7? 0010010 = spdi 7? 0010011 = dvdd 7? 0010100 = mbs 7? 0010101 = qvcp 7? 0010110 = ao 7? 0010111 = ai 7? 0011000 = pci1 aperture 7? 0011001 = pci2 aperture 7? 0011010 = xio aperture 7? 0011011 = dma (tm3260 to pci space) 7? 1011100 = null/error target 7? 1011101 = network controller con?uration aperture 9 reserved - ignore upon read. write as zeroes. 8 err_tout_read r 0x0 value of cmd_read signal during error or timeout 1 = read operation 0 = write operation 7:4 err_tout_mask[3:0] r 0x0 value of cmd_mask during error or timeout indicates which bytes were to be read or written. 3:2 reserved - ignore upon read. write as zeroes. 1 err_ack r 0 error or timeout 0 = timeout 1 = error 0 reserved - ignore upon read. write as zeroes. offset 0x10 3fd8 bc_int_clr_enable 31:2 reserved - ignore upon read. write as zeroes. 1 int_clr_enable_ tout w 0 timeout interrupt enable clear register. this is written by software to clear the interrupt enable (bit 1 of bc_int_en). 1 = timeout interrupt enable is cleared 0 = timeout interrupt enable is unchanged. table 2: dcs controller_trimedia con?uration registers (rev 0.32) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 30: dcs network 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 30-6 0 int_clr_enable_ error w 0 error interrupt enable clear register. this is written by software to clear the interrupt enable (bit 0 of bc_int_en). 1 = error interrupt enable is cleared 0 = error interrupt enable is unchanged. offset 0x10 3fdc bc_int_set_enable 31:2 reserved - ignore upon read. write as zeroes. 1 int_set_enable_ tout w 0 timeout interrupt enable set register. this is written by software to set the interrupt enable (bit 1 of bc_int_en). 1 = timeout interrupt enable is set 0 = timeout interrupt enable is unchanged. 0 int_set_enable_ error w 0 error interrupt enable set register. this is written by software to set the interrupt enable (bit 0 of bc_int_en). 1 = error interrupt enable is set 0 = error interrupt enable is unchanged. offset 0x10 3fe0 bc_int_status 31:2 reserved - ignore upon read. write as zeroes. 1 int_status_tout r 0 timeout interrupt status. reports any pending timeout interrupts: 1 = timeout interrupt pending: mmio bus controller has generated a timeout because a target has violated the programmable limit for timeout (see bc_tout). 0 = timeout interrupt is not pending. 0 int_status_error r 0 error interrupt status. reports any pending error interrupts: 1 = error interrupt pending, meaning bus controller has detected an error acknowledge from a target. 0 = error interrupt is not pending. offset 0x10 3fe4 bc_int_en 31:2 reserved - ignore upon read. write as zeroes. 1 int_enable_tout r/w 0 timeout interrupt enable register 1 = timeout interrupt is enabled 0 = timeout interrupt is disabled. 0 int_enable_error r/w 0 timeout interrupt enable register 1 = error interrupt is enabled 0 = error interrupt is disabled. offset 0x10 3fe8 bc_int_clr 31:2 reserved - ignore upon read. write as zeroes. 1 int_clear_tout w 0 timeout interrupt clear register. this is written by software to clear the interrupt. 1 = timeout interrupt is cleared 0 = timeout interrupt is unchanged. 0 int_clear_error w 0 error interrupt clear register. this is written by software to clear the interrupt. 1 = error interrupt is cleared 0 = error interrupt is unchanged. table 2: dcs controller_trimedia con?uration registers (rev 0.32) ?ontinued bit symbol acces s value description
philips semiconductors pnx15xx series volume 1 of 1 chapter 30: dcs network 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 30-7 offset 0x10 3fec bc_int_set 31:2 reserved - ignore upon read. write as zeroes. 1 int_set_tout w 0 timeout interrupt set register. allows software to set interrupts. 1 = timeout interrupt is set 0 = timeout interrupt is unchanged. 0 int_set_error w 0 error interrupt set register. allows software to set interrupts. 1 = error interrupt is set 0 = error interrupt is unchanged. offset 0x10 3ffc bc_module_id 31:16 module_id[15:0] r 0xa049 unique 16-bit code. this value varies depending on the value speci?d at compile time for each dcs controller 15:12 majrev[3:0] r 0x0 major revision id 11:8 minrev[3:0] r 0x0 minor revision id 7:0 module_aperture_ size[7:0] r 0x00 aperture size = 4 kb*(bit_value+1), so 0 means 4 kb (the default). table 2: dcs controller_trimedia con?uration registers (rev 0.32) ?ontinued bit symbol acces s value description
1. introduction please refer to ?he tm3260 architecture databook? rev. 1.02, july 12 2004, or later revision, for a complete detailed description of the tm3260 architecture. refer to chapter 3 system on chip resources section 6.3 on page 3- 15 for details on how tm3260 is connected in pnx15xx series system on chip device. chapter 31: tm3260 pnx15xx series data book ?volume 1 of 1 rev. 2 ?1 december 2004 product data sheet
philips semiconductors pnx15xx series volume 1 of 1 chapter 31: tm3260 12nc 9397 750 14321 ?koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. product data sheet rev. 2 ?1 december 2004 31-2
philips semiconductors pnx15xx series volume 1 of 1 connected media processor koninklijke philips electronics n.v. 2002-2003-2004. all rights reserved. published in the u.s.a. all rights are reserved. reproduction in whole or in part is prohibited without the prior written consent of the copyright owner. the information presented in this document does not form part of any quotation or contract, is believed to be accurate and reliable and may be changed without notice. no liability will be accepted by the publisher for any consequence of its use. publication thereof does not convey nor imply any license under patent- or other industrial or intellectual property rights. 1. data sheet status [1] please consult the most recently issued data sheet before initiating or completing a design. [2] the product status of the device(s) described in this data sheet may have changed since this data sheet was published. the latest information is ava ilable on the internet at url http:/ /www.semiconductors.philips.com. [3] for data sheets describing multiple type numbers, the highest-level product status determines the data sheet status. 2. de?itions short-form specification the data in a short-form speci?ation is extracted from a full data sheet with the same type number and title. for detailed information see the relevant data sheet or data handbook. limiting values definition limiting values given are in accordance with the absolute maximum rating system (iec 60134). stress above one or more of the limiting values may cause permanent damage to the device. these are stress ratings only and operation of the device at thes e or at any other conditions above those given in the characteristics sections of the specification is not implied. exposure to limiting values for extended periods may affect device reliability. application information applications that are described herein for any of these products are for illustrative purposes only. philips semiconductors mak e no representation or warranty that such applications will be suitable for the speci?d use without further testing or modi?ation. 3. disclaimers life support these products are not designed for use in life support appliances, devices, or systems where malfunction of these products can reasonably be expected to result in personal injury. philips semiconductors customers using or selling these products for use in such appl ications do so at their own risk and agree to fully indemnify philips semiconductors for any damages resulting from such application. right to make changes philips semiconductors reserves the right to make changes in the products - including circuits, standard cells, and/or software - described or contained herein in order to improve design and/or performance. when the product is in full production (status ?roduction?, relevant changes will be communicated via a customer product/process change noti?ation (cpcn). philips semiconductors assumes no responsibility or liab ility for the use of any of these products, conveys no license or title under any patent, copyright, or mask work right to these products, and makes no rep resentations or warranties that these products are free from patent, copyright, or mask work right infringement, unless otherwise speci?d. 4. licenses 5. trademarks trimedia is a trademark owned by koninklijke philips electronics n.v. nexperia is a trademark of koninklijke philips electronics n.v. 6. contact information for additional information, please visit http://www.semiconductors.philips.com . for sales of?e addresses, send e-mail to: sales.addresses@www.semiconductors.philips.com . fax: +31 40 27 24825 level data sheet status [1] product status [2][3] de?ition i objective data development this data sheet contains data from the objective speci?ation for product development. philips semiconductors reserves the right to change the speci?ation in any manner without notice. ii preliminary data quali?ation this data sheet contains data from the preliminary speci?ation. supplementary data will be published at a later date. philips semiconductors reserves the right to change the speci?ation without notice, in order to improve the design and supply the best possible product. iii product data production this data sheet contains data from the product speci?ation. philips semiconductors reserves the right to make changes at any time in order to improve the design, manufacturing and supply. relevant changes will be communicated via a customer product/process change noti?ation (cpcn). purchase of philips i 2 c components conveys a license under the philips?i 2 c patent to use the components in the i 2 c system provided the system conforms to the speci?ation de?ed by philips. this i 2 c speci?ation can be ordered using the code 9398 393 40011. purchase of philips rc5 components conveys a license under the philips rc5 patent to use the components in rc5 system products conforming to the rc5 standard uatm-5000 for allocation of remote control commands de?ed by philips.


▲Up To Search▲   

 
Price & Availability of PNX1502EG

All Rights Reserved © IC-ON-LINE 2003 - 2022  

[Add Bookmark] [Contact Us] [Link exchange] [Privacy policy]
Mirror Sites :  [www.datasheet.hk]   [www.maxim4u.com]  [www.ic-on-line.cn] [www.ic-on-line.com] [www.ic-on-line.net] [www.alldatasheet.com.cn] [www.gdcy.com]  [www.gdcy.net]


 . . . . .
  We use cookies to deliver the best possible web experience and assist with our advertising efforts. By continuing to use this site, you consent to the use of cookies. For more information on cookies, please take a look at our Privacy Policy. X